projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Fix: use off_t type for lseek function return value to avoid overflow
[lttng-tools.git]
/
src
/
bin
/
lttng-sessiond
/
cmd.c
diff --git
a/src/bin/lttng-sessiond/cmd.c
b/src/bin/lttng-sessiond/cmd.c
index 9d742536852b4880f30d7245f71d32567a94bc5e..081648889cebdc8e645e76c6b176d60a7a8d2faf 100644
(file)
--- a/
src/bin/lttng-sessiond/cmd.c
+++ b/
src/bin/lttng-sessiond/cmd.c
@@
-3420,10
+3420,12
@@
static
int clear_metadata_file(int fd)
{
int ret;
+ off_t lseek_ret;
- ret = lseek(fd, 0, SEEK_SET);
- if (ret < 0) {
+
lseek_
ret = lseek(fd, 0, SEEK_SET);
+ if (
lseek_
ret < 0) {
PERROR("lseek");
+ ret = -1;
goto end;
}
This page took
0.025787 seconds
and
4
git commands to generate.