projects
/
platform
/
upstream
/
efl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
149a0aa
)
elementary: fix segmentation faults when using elm_prefs
author
Jean Guyomarc'h
<jean@guyomarch.bzh>
Fri, 12 Aug 2016 14:20:34 +0000
(16:20 +0200)
committer
Jean Guyomarc'h
<jean@guyomarch.bzh>
Fri, 12 Aug 2016 14:28:32 +0000
(16:28 +0200)
There are several cases of failure:
- if regex is NULL, regfree(regex) may lead to segmentation fault
(undefined behaviour, as specified in POSIX.1)
- if regex is not NULL, there are cases of use-after-free.
@fix
src/modules/elementary/prefs/elm_entry.c
patch
|
blob
|
history
diff --git
a/src/modules/elementary/prefs/elm_entry.c
b/src/modules/elementary/prefs/elm_entry.c
index
5253202
..
966838e
100644
(file)
--- a/
src/modules/elementary/prefs/elm_entry.c
+++ b/
src/modules/elementary/prefs/elm_entry.c
@@
-207,7
+207,6
@@
elm_prefs_entry_add(const Elm_Prefs_Item_Iface *iface EINA_UNUSED,
elm_entry_markup_filter_append(obj, elm_entry_filter_limit_size, &limit);
elm_layout_text_set(obj, NULL, spec.s.placeholder);
- regfree(regex);
return obj;
}