projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8cb1e44
)
* be more accurate, len needs to be at least sizeof(magic)
author
Wilfried Göesgens
<willi@citadel.org>
Wed, 27 Jan 2010 23:35:41 +0000
(23:35 +0000)
committer
Wilfried Göesgens
<willi@citadel.org>
Wed, 27 Jan 2010 23:35:41 +0000
(23:35 +0000)
citadel/database.c
patch
|
blob
|
history
diff --git
a/citadel/database.c
b/citadel/database.c
index ed9019288534c18f594f325eef25f0c45fb42d6b..caa0e3b46c6b71c52d66e654adb8eccc36984f36 100644
(file)
--- a/
citadel/database.c
+++ b/
citadel/database.c
@@
-493,7
+493,7
@@
void cdb_decompress_if_necessary(struct cdbdata *cdb)
if ((cdb == NULL) ||
(cdb->ptr == NULL) ||
- (cdb->len
== 0
) ||
+ (cdb->len
< sizeof(magic)
) ||
(memcmp(cdb->ptr, &magic, sizeof(magic))))
return;