projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: consumerd: type confusion in lttng_consumer_send_error
[lttng-tools.git]
/
src
/
common
/
spawn-viewer.c
diff --git
a/src/common/spawn-viewer.c
b/src/common/spawn-viewer.c
index 26fe9199faab60fbbae724ebf3dd7922edb2a73f..13cc79213e72776361ce6919b1fcc5f891dca95a 100644
(file)
--- a/
src/common/spawn-viewer.c
+++ b/
src/common/spawn-viewer.c
@@
-1,9
+1,9
@@
/*
/*
- * Copyright (C) 2011
David Goulet <david.goulet@polymtl.ca>
+ * Copyright (C) 2011
EfficiOS Inc.
* Copyright (C) 2014 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
* Copyright (C) 2020 Francis Deslauriers <francis.deslauriers@efficios.com>
*
* Copyright (C) 2014 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
* Copyright (C) 2020 Francis Deslauriers <francis.deslauriers@efficios.com>
*
- * SPDX-License-Identifier:
GPL-2.0
-only
+ * SPDX-License-Identifier:
LGPL-2.1
-only
*
*/
*
*/
@@
-12,10
+12,10
@@
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
-#include <errno.h>
#include <lttng/constant.h>
#include <lttng/constant.h>
+#include <common/compat/errno.h>
#include "error.h"
#include "macros.h"
#include "spawn-viewer.h"
#include "error.h"
#include "macros.h"
#include "spawn-viewer.h"
@@
-69,7
+69,7
@@
static char **alloc_argv_from_user_opts(char *opts, const char *trace_path)
{
int i = 0, ignore_space = 0;
unsigned int num_opts = 1;
{
int i = 0, ignore_space = 0;
unsigned int num_opts = 1;
- char **argv, *token = opts;
+ char **argv, *token = opts
, *saveptr = NULL
;
/* Count number of arguments. */
do {
/* Count number of arguments. */
do {
@@
-91,13
+91,13
@@
static char **alloc_argv_from_user_opts(char *opts, const char *trace_path)
goto error;
}
goto error;
}
- token = strtok
(opts, " "
);
+ token = strtok
_r(opts, " ", &saveptr
);
while (token != NULL) {
argv[i] = strdup(token);
if (argv[i] == NULL) {
goto error;
}
while (token != NULL) {
argv[i] = strdup(token);
if (argv[i] == NULL) {
goto error;
}
- token = strtok
(NULL, " "
);
+ token = strtok
_r(NULL, " ", &saveptr
);
i++;
}
i++;
}
This page took
0.028875 seconds
and
4
git commands to generate.