projects
/
platform
/
upstream
/
libsolv.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0cf35d7
)
- fix error handling in solv_xfopen_buf
author
Michael Schroeder
<mls@suse.de>
Mon, 10 Sep 2012 16:23:13 +0000
(18:23 +0200)
committer
Michael Schroeder
<mls@suse.de>
Mon, 10 Sep 2012 16:23:13 +0000
(18:23 +0200)
ext/solv_xfopen.c
patch
|
blob
|
history
diff --git
a/ext/solv_xfopen.c
b/ext/solv_xfopen.c
index
4de122a
..
429086a
100644
(file)
--- a/
ext/solv_xfopen.c
+++ b/
ext/solv_xfopen.c
@@
-441,8
+441,8
@@
solv_xfopen_buf(const char *fn, char **bufp, size_t *buflp, const char *mode)
bc->freemem = *bufp;
if (!fp)
{
- *bc->bufp = solv_free(*bc->bufp);
-
*bc->buflp = 0
;
+ if (*mode == 'w')
+
*bc->bufp = solv_free(*bc->bufp)
;
cookie_bufclose(bc);
}
return fp;