Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | The file_wd_isdir() function must honor the symlinks options. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | noSymlinks |
Files: | files | file ages | folders |
SHA1: |
de053c778cb822713e06be897adabab1 |
User & Date: | mistachkin 2017-02-01 02:42:28.905 |
Context
2017-02-01
| ||
04:40 | Rename and repurpose '--no-symlinks' into '--no-dir-symlinks', to prevent traversing into symlinked directories. Make the '--verily' option to 'clean' imply '--no-dir-symlinks'. ... (check-in: 66406ae9 user: mistachkin tags: noSymlinks) | |
02:42 | The file_wd_isdir() function must honor the symlinks options. ... (check-in: de053c77 user: mistachkin tags: noSymlinks) | |
02:32 | Attempt to always enforce the --no-symlinks option. ... (check-in: 35e37e9b user: mistachkin tags: noSymlinks) | |
Changes
Changes to src/file.c.
︙ | ︙ | |||
307 308 309 310 311 312 313 | zFN = mprintf("%s", zFilename); file_simplify_name(zFN, -1, 0); rc = getStat(zFN, 1); if( rc ){ rc = 0; /* It does not exist at all. */ }else if( S_ISDIR(fileStat.st_mode) ){ rc = 1; /* It exists and is a real directory. */ | | | 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 | zFN = mprintf("%s", zFilename); file_simplify_name(zFN, -1, 0); rc = getStat(zFN, 1); if( rc ){ rc = 0; /* It does not exist at all. */ }else if( S_ISDIR(fileStat.st_mode) ){ rc = 1; /* It exists and is a real directory. */ }else if( db_allow_symlinks() && S_ISLNK(fileStat.st_mode) ){ Blob content; blob_read_link(&content, zFN); /* It exists and is a link. */ rc = file_wd_isdir(blob_str(&content)); /* Points to directory? */ blob_reset(&content); }else{ rc = 2; /* It exists and is something else. */ } |
︙ | ︙ |