diff options
| author | Paul Traina <pst@FreeBSD.org> | 1996-02-23 17:58:34 +0000 |
|---|---|---|
| committer | Paul Traina <pst@FreeBSD.org> | 1996-02-23 17:58:34 +0000 |
| commit | f683da834674942b3c9c1e5cfedbfc5cb6f4cab1 (patch) | |
| tree | 559bfa006873a98083798e5f200b7dae346bc67b /lib/libc | |
| parent | 6ddbd8939153a26f108535ce4b51833ceac5a034 (diff) | |
Notes
Diffstat (limited to 'lib/libc')
| -rw-r--r-- | lib/libc/db/hash/hash.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libc/db/hash/hash.c b/lib/libc/db/hash/hash.c index 6a23f3d801cb..e062ac7b1dcd 100644 --- a/lib/libc/db/hash/hash.c +++ b/lib/libc/db/hash/hash.c @@ -122,7 +122,8 @@ __hash_open(file, flags, mode, info, dflags) new_table = 0; if (!file || (flags & O_TRUNC) || - (stat(file, &statbuf) && (errno == ENOENT))) { + (stat(file, &statbuf) && (errno == ENOENT)) || + statbuf.st_size == 0) { if (errno == ENOENT) errno = 0; /* Just in case someone looks at errno */ new_table = 1; |
