diff options
author | Stephen Gallagher <sgallagh@redhat.com> | 2011-12-09 13:38:31 -0500 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2011-12-09 13:39:35 -0500 |
commit | 9406fc6a1813ca99edca6a630bacc0a148121b52 (patch) | |
tree | 95b5e3bb05dc723b681433e6452524ecf1bd94b0 /src/util | |
parent | bb57f6003fa42856d0578ac27eb57e798be9bbb5 (diff) | |
download | sssd-9406fc6a1813ca99edca6a630bacc0a148121b52.tar.gz sssd-9406fc6a1813ca99edca6a630bacc0a148121b52.tar.bz2 sssd-9406fc6a1813ca99edca6a630bacc0a148121b52.zip |
Fix potential resource leak in backup_file.c
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/backup_file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util/backup_file.c b/src/util/backup_file.c index fb1604b9..ba776404 100644 --- a/src/util/backup_file.c +++ b/src/util/backup_file.c @@ -68,7 +68,7 @@ int backup_file(const char *src_file, int dbglvl) dst_fd = open(dst_file, O_CREAT|O_EXCL|O_WRONLY, 0600); ret = errno; - if (dst_fd > 0) break; + if (dst_fd >= 0) break; if (ret != EEXIST) { DEBUG(dbglvl, ("Error (%d [%s]) opening destination file %s\n", |