projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: wrong check after malloc in buffer registry
[lttng-tools.git]
/
src
/
bin
/
lttng-sessiond
/
buffer-registry.c
diff --git
a/src/bin/lttng-sessiond/buffer-registry.c
b/src/bin/lttng-sessiond/buffer-registry.c
index ad103d1dec36e2afcf7cfd1f9861feda044aa198..e64e4375ed139ab0c51d2f300a6dd47b96a4ebfc 100644
(file)
--- a/
src/bin/lttng-sessiond/buffer-registry.c
+++ b/
src/bin/lttng-sessiond/buffer-registry.c
@@
-120,7
+120,7
@@
int buffer_reg_uid_create(int session_id, uint32_t bits_per_long, uid_t uid,
}
reg->registry = zmalloc(sizeof(struct buffer_reg_session));
}
reg->registry = zmalloc(sizeof(struct buffer_reg_session));
- if (!reg) {
+ if (!reg
->registry
) {
PERROR("zmalloc buffer registry uid session");
ret = -ENOMEM;
goto error;
PERROR("zmalloc buffer registry uid session");
ret = -ENOMEM;
goto error;
@@
-240,7
+240,7
@@
int buffer_reg_pid_create(int session_id, struct buffer_reg_pid **regp)
}
reg->registry = zmalloc(sizeof(struct buffer_reg_session));
}
reg->registry = zmalloc(sizeof(struct buffer_reg_session));
- if (!reg) {
+ if (!reg
->registry
) {
PERROR("zmalloc buffer registry pid session");
ret = -ENOMEM;
goto error;
PERROR("zmalloc buffer registry pid session");
ret = -ENOMEM;
goto error;
This page took
0.023241 seconds
and
4
git commands to generate.