From: Jon Bernard Date: Mon, 13 May 2013 15:38:17 +0000 (-0400) Subject: Remove bashism in lttng-syscalls-generate-headers.sh X-Git-Tag: v2.3.0-rc1~32 X-Git-Url: http://git.liburcu.org/?p=lttng-modules.git;a=commitdiff_plain;h=db55ef8073facd9622cbc6ac1be52abeca269126 Remove bashism in lttng-syscalls-generate-headers.sh Options to echo are not portable. In particular, the 'echo -e' option is implemented by some shells, including bash, to expand escape sequences. However, dash is one of the other family of shells that instead expands escape sequences by default. The printf command is portable and much more reliable. Signed-off-by: Mathieu Desnoyers --- diff --git a/instrumentation/syscalls/lttng-syscalls-generate-headers.sh b/instrumentation/syscalls/lttng-syscalls-generate-headers.sh index 046dc067..1754ae89 100755 --- a/instrumentation/syscalls/lttng-syscalls-generate-headers.sh +++ b/instrumentation/syscalls/lttng-syscalls-generate-headers.sh @@ -59,7 +59,7 @@ if [ "$CLASS" = integers ]; then NRARGS=0 -echo -e \ +printf \ 'SC_DECLARE_EVENT_CLASS_NOARGS(syscalls_noargs,\n'\ ' TP_STRUCT__entry(),\n'\ ' TP_fast_assign(),\n'\