projects
/
horde.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
99753d8
)
Don't leak errors from unserialize
author
Chuck Hagenbuch
<chuck@horde.org>
Tue, 9 Nov 2010 18:48:33 +0000
(13:48 -0500)
committer
Chuck Hagenbuch
<chuck@horde.org>
Tue, 9 Nov 2010 18:48:52 +0000
(13:48 -0500)
ansel/lib/Storage.php
patch
|
blob
|
history
diff --git
a/ansel/lib/Storage.php
b/ansel/lib/Storage.php
index
2bca772
..
9d71991
100644
(file)
--- a/
ansel/lib/Storage.php
+++ b/
ansel/lib/Storage.php
@@
-297,7
+297,8
@@
class Ansel_Storage
if (!count($overrides) && $GLOBALS['conf']['ansel_cache']['usecache'] &&
($gallery = $GLOBALS['injector']->getInstance('Horde_Cache')->get('Ansel_Gallery' . $gallery_id, $GLOBALS['conf']['cache']['default_lifetime'])) !== false) {
- return unserialize($gallery);
+ $cached_gallery = @unserialize($gallery);
+ if ($cached_gallery) { return $cached_gallery; }
}
try {