chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
4a207bb
)
localectl: fix memleak, jump to finish before returning
author
Michal Sekletar
<msekleta@redhat.com>
Fri, 26 Oct 2012 12:15:00 +0000
(14:15 +0200)
committer
Zbigniew Jędrzejewski-Szmek
<zbyszek@in.waw.pl>
Sun, 28 Oct 2012 00:14:40 +0000
(
02:14
+0200)
src/locale/localectl.c
patch
|
blob
|
history
diff --git
a/src/locale/localectl.c
b/src/locale/localectl.c
index c05eba0d3edebfcdedbf1cc20d47230547ddae3b..84feb25d521d0a6d612436b34a12dfc5f30f1e3b 100644
(file)
--- a/
src/locale/localectl.c
+++ b/
src/locale/localectl.c
@@
-354,7
+354,8
@@
static int list_locales(DBusConnection *bus, char **args, unsigned n) {
h->locrectab_offset + h->locrectab_size > st.st_size ||
h->sumhash_offset + h->sumhash_size > st.st_size) {
log_error("Invalid archive file.");
h->locrectab_offset + h->locrectab_size > st.st_size ||
h->sumhash_offset + h->sumhash_size > st.st_size) {
log_error("Invalid archive file.");
- return -EBADMSG;
+ r = -EBADMSG;
+ goto finish;
}
e = (const struct namehashent*) ((const uint8_t*) p + h->namehash_offset);
}
e = (const struct namehashent*) ((const uint8_t*) p + h->namehash_offset);