mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
common: Never remove /dev/null.
* common/sysutils.c (gnupg_remove): Detect /dev/null. -- GnuPG-bug-id: 6556
This commit is contained in:
parent
a02f3cc4e8
commit
7f9e05d73f
@ -810,6 +810,11 @@ gnupg_remove (const char *fname)
|
||||
return -1;
|
||||
return 0;
|
||||
#else
|
||||
/* It is common to use /dev/null for testing. We better don't
|
||||
* remove that file. */
|
||||
if (fname && !strcmp (fname, "/dev/null"))
|
||||
return 0;
|
||||
else
|
||||
return remove (fname);
|
||||
#endif
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user