[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: mkdir -p and network drives
From: |
Paul Eggert |
Subject: |
Re: mkdir -p and network drives |
Date: |
Thu, 05 May 2005 20:47:00 -0700 |
User-agent: |
Gnus/5.1006 (Gnus v5.10.6) Emacs/21.4 (gnu/linux) |
Eric Blake <address@hidden> writes:
>> + if (do_chdir && dirpath[0] == '/')
>> + {
>> + /* POSIX says "//" might be special, so chdir to "//" if the
>> + file name starts with exactly two slashes. */
>> + char const *root = "//" + (dirpath[1] != '/' || dirpath[2] == '/');
>
> Oops - buffer overflow bug. dirpath[2] is past the end of the string on
> dirpath of "/",
If dirpath is "/", then dirpath[1] != '/' is true, so dirpath[2] isn't
evaluated.
- Re: mkdir -p and network drives, (continued)
- Re: mkdir -p and network drives, Igor Pechtchanski, 2005/05/05
- RE: mkdir -p and network drives, Dave Korn, 2005/05/05
- RE: mkdir -p and network drives, Igor Pechtchanski, 2005/05/06
- Re: mkdir -p and network drives, Paul Eggert, 2005/05/06
- Re: mkdir -p and network drives, Christopher Faylor, 2005/05/06
- Re: mkdir -p and network drives, Paul Eggert, 2005/05/07
- Message not available
- Re: mkdir -p and network drives, Eric Blake, 2005/05/07
- Re: mkdir -p and network drives, Jim Meyering, 2005/05/06
- cvs mirror stuck and lists.gnu.org offline (was: mkdir -p and network drives), Bob Proulx, 2005/05/05
Re: mkdir -p and network drives, Eric Blake, 2005/05/05