Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

RE: PATCH: pws-21: minor fixes



>
> I looked again at Andrej's logfile from compiling with
> --enable-lfs, and it
> was even less interesting than the first time.  I've only made a couple of
> changes to the use of long integers, where it's just possible a
> user-supplied string might be too long.  Otherwise, there are still places
> where there are conversions for things like the lengths of strings, sizes
> of windows, return values, pids, line numbers, times (time_t is
> used fairly
> consistently for these and is usually 32-bit) and so on, where there
> doesn't seem any point in using longer integers.
>

One thing, that still bothers me, is mapfile. In case of LFS (64-on-32)
address space is most probably limited to 32 bits, that means, it is
impossible to map large file. I do not supose, anybody would do this on
purpose, but what happens if somebody makes mistake? Currently file size is
silently passed to mmap ... that truncates it and (in worst case) maps some
part of file. And even worse, can file be truncated as a result?

Or am I just paranoid?

/andrej



Messages sorted by: Reverse Date, Date, Thread, Author