Differences From:
File
src/add.c
part of check-in
[c7278fd013]
- Win32 port now functional except network operations. This commit was done on windows :-). See win32.txt for status of all commands. No networking commands are functional yet. All path operations are now functioning.
by
jnc on
2007-09-22 06:47:11.
Also file
src/add.c
part of check-in
[3c5482959c]
- Merge in the w32 changes.
by
drh on
2007-09-22 19:43:55.
[view]
To:
File
src/add.c
part of check-in
[da9d38e2c3]
- Fix the "add" command is that it does not allow users to accidently
add files that contain shell wildcard characters.
by
drh on
2007-10-15 20:45:11.
Also file
src/add.c
part of check-in
[d0305b305a]
- Merged mainline into my branch to get the newest application.
by
aku on
2007-12-05 08:07:46.
[view]
@@ -64,8 +64,11 @@
file_tree_name(zName, &pathname);
zPath = blob_str(&pathname);
if( strcmp(zPath, "manifest")==0 || strcmp(zPath, "_FOSSIL_")==0 ){
fossil_fatal("cannot add %s", zPath);
+ }
+ if( !file_is_simple_pathname(zPath) ){
+ fossil_fatal("filename contains illegal characters: %s", zPath);
}
if( db_exists("SELECT 1 FROM vfile WHERE pathname=%Q", zPath) ){
db_multi_exec("UPDATE vfile SET deleted=0 WHERE pathname=%Q", zPath);
}else{