summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
5f98d63)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
strncpy(stream_shm_path, shm_path, PATH_MAX);
stream_shm_path[PATH_MAX - 1] = '\0';
ret = snprintf(cpu_nr, UINT_MAX_STR_LEN, "%u", cpu);
strncpy(stream_shm_path, shm_path, PATH_MAX);
stream_shm_path[PATH_MAX - 1] = '\0';
ret = snprintf(cpu_nr, UINT_MAX_STR_LEN, "%u", cpu);
- if (ret != 1) {
- ret = -1;
+ if (ret < 0) {
+ PERROR("snprintf");
goto end;
}
strncat(stream_shm_path, cpu_nr,
goto end;
}
strncat(stream_shm_path, cpu_nr,