diff options
Diffstat (limited to 'app-mobilephone/smstools/files/2.2.1-skip-dirlock.patch')
-rw-r--r-- | app-mobilephone/smstools/files/2.2.1-skip-dirlock.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/app-mobilephone/smstools/files/2.2.1-skip-dirlock.patch b/app-mobilephone/smstools/files/2.2.1-skip-dirlock.patch new file mode 100644 index 000000000000..64336eed98a1 --- /dev/null +++ b/app-mobilephone/smstools/files/2.2.1-skip-dirlock.patch @@ -0,0 +1,38 @@ +--- src/extras.c.orig 2006-06-15 10:45:59.000000000 +0100 ++++ src/extras.c 2006-06-15 10:45:39.000000000 +0100 +@@ -178,20 +178,21 @@ + stat(filename,&statbuf); + if (S_ISDIR(statbuf.st_mode)==0) /* Is this a directory? */ + { +- /* File found, check for lock file */ +- if (strstr(filename,".LOCK")==0) /* Is the file a lock file itself? */ +- if (!islocked(filename)) /* no, is there a lock file for this file? */ +- { +- /* check if the file grows at the moment (another program writes to it) */ +- int groesse1; +- int groesse2; +- groesse1=statbuf.st_size; +- sleep(1); +- stat(filename,&statbuf); +- groesse2=statbuf.st_size; +- if (groesse1==groesse2) +- found=1; +- } ++ /* File found, check for lock file and skip portage directory locks */ ++ if (strstr(filename,".keep")==0) /* Is it a portage directory lock? */ ++ if (strstr(filename,".LOCK")==0) /* Is the file a lock file itself? */ ++ if (!islocked(filename)) /* no, is there a lock file for this file? */ ++ { ++ /* check if the file grows at the moment (another program writes to it) */ ++ int groesse1; ++ int groesse2; ++ groesse1=statbuf.st_size; ++ sleep(1); ++ stat(filename,&statbuf); ++ groesse2=statbuf.st_size; ++ if (groesse1==groesse2) ++ found=1; ++ } + } + } + closedir(dirdata); |