projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
tests: Correct use of taskset in snapshot tests
[lttng-tools.git]
/
tests
/
regression
/
tools
/
notification
/
default_pipe_size_getter.cpp
diff --git
a/tests/regression/tools/notification/default_pipe_size_getter.cpp
b/tests/regression/tools/notification/default_pipe_size_getter.cpp
index febcc0a067ea0224e4b53ab6f351d8a8d156b894..34eb3cdd35fd514498f1169da196239d7d1c0ecb 100644
(file)
--- a/
tests/regression/tools/notification/default_pipe_size_getter.cpp
+++ b/
tests/regression/tools/notification/default_pipe_size_getter.cpp
@@
-13,24
+13,24
@@
#define _GNU_SOURCE
#endif
#define _GNU_SOURCE
#endif
-#include <unistd.h>
+#include <common/error.hpp>
+#include <common/pipe.hpp>
+
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
-
-#include <common/pipe.hpp>
-#include <common/error.hpp>
+#include <unistd.h>
int lttng_opt_verbose;
int lttng_opt_mi;
int lttng_opt_quiet;
int lttng_opt_verbose;
int lttng_opt_mi;
int lttng_opt_quiet;
+namespace {
#ifdef __linux__
/*
* Return the default pipe buffer size or a negative error.
*/
#ifdef __linux__
/*
* Return the default pipe buffer size or a negative error.
*/
-static
-int get_pipe_size(void)
+int get_pipe_size()
{
int ret;
/*
{
int ret;
/*
@@
-57,7
+57,6
@@
end:
return ret;
}
#elif defined(__FreeBSD__)
return ret;
}
#elif defined(__FreeBSD__)
-static
int get_pipe_size(void)
{
return 65536;
int get_pipe_size(void)
{
return 65536;
@@
-65,8
+64,9
@@
int get_pipe_size(void)
#else
#error "Implement get_pipe_size() for your platform."
#endif
#else
#error "Implement get_pipe_size() for your platform."
#endif
+} /* namespace */
-int main(
void
)
+int main()
{
int ret;
{
int ret;
@@
-75,8
+75,8
@@
int main(void)
return EXIT_FAILURE;
}
return EXIT_FAILURE;
}
- /* Print the pipe buffer size to stdout */
+ /* Print the pipe buffer size to stdout
.
*/
printf("%d\n", ret);
printf("%d\n", ret);
- return
EXIT_SUCCESS;
+ return EXIT_SUCCESS;
}
}
This page took
0.023761 seconds
and
4
git commands to generate.