projects
/
framework
/
security
/
libprivilege-control.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4d51adc
)
Fixing segfault in get_app_gids when app_id = NULL
author
Zbigniew Jasinski
<z.jasinski@samsung.com>
Fri, 5 Jul 2013 07:54:18 +0000
(09:54 +0200)
committer
Zbigniew Jasinski
<z.jasinski@samsung.com>
Fri, 5 Jul 2013 07:54:46 +0000
(09:54 +0200)
Change-Id: I1b9e182366da921f1a6bfee50a87e694ca3c1f7f
src/access-db.c
patch
|
blob
|
history
diff --git
a/src/access-db.c
b/src/access-db.c
index
e635a3a
..
dcee10a
100644
(file)
--- a/
src/access-db.c
+++ b/
src/access-db.c
@@
-339,6
+339,11
@@
int get_app_gids(const char *app_id, unsigned **gids, int *len)
goto out;
}
+ if (NULL == app_id) {
+ *len = 0;
+ return PC_OPERATION_SUCCESS;
+ }
+
if (!strcmp(app_id, app_id_tmp)) {
unsigned *gids_realloc = realloc(*gids, sizeof(unsigned) * (*len + 1));
if (gids_realloc == NULL) {