Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2019-11-11 10:12:09 +0000
committerHenrik Rentz-Reichert2019-11-11 10:12:09 +0000
commitfa282db53c7f2e6dc11648b17f1730e49addf9e8 (patch)
tree97454a8564bcc3b5da8a80eaa1d86a2dd917b21b /runtime/org.eclipse.etrice.runtime.c
parent463d43545df7530c2de22853ebd67e5616119657 (diff)
downloadorg.eclipse.etrice-fa282db53c7f2e6dc11648b17f1730e49addf9e8.tar.gz
org.eclipse.etrice-fa282db53c7f2e6dc11648b17f1730e49addf9e8.tar.xz
org.eclipse.etrice-fa282db53c7f2e6dc11648b17f1730e49addf9e8.zip
Bug 552897 - [runtime.c] reduce warnings using C compilerv_3.0.1
Added missing includes. Change-Id: I6814052eb6ee8b91d81909b70ac6286289b7dc92
Diffstat (limited to 'runtime/org.eclipse.etrice.runtime.c')
-rw-r--r--runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etConsoleLogger.c2
-rw-r--r--runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etLogger.c6
-rw-r--r--runtime/org.eclipse.etrice.runtime.c/src/common/runtime/etRuntime.c2
-rw-r--r--runtime/org.eclipse.etrice.runtime.c/src/platforms/MT_POSIX_GENERIC_GCC/etDatatypes.h1
4 files changed, 7 insertions, 4 deletions
diff --git a/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etConsoleLogger.c b/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etConsoleLogger.c
index 60c21cfa9..f515fe50f 100644
--- a/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etConsoleLogger.c
+++ b/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etConsoleLogger.c
@@ -35,7 +35,7 @@ static void* etConsoleSender_getBuffer(etBufferSender* self, size_t size) {
}
void etConsoleSender_sendBuffer(etBufferSender* self, void* buffer, size_t size) {
- fprintf(stdout, buffer);
+ fprintf(stdout, "%s", (char*) buffer);
fflush(stdout);
}
diff --git a/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etLogger.c b/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etLogger.c
index ceee150a9..329ba9463 100644
--- a/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etLogger.c
+++ b/runtime/org.eclipse.etrice.runtime.c/src/common/debugging/etLogger.c
@@ -12,12 +12,12 @@
*
*******************************************************************************/
-#include "debugging/etLogger.h"
-#include "osal/etTime.h"
-
#include <stdarg.h>
#include <string.h>
+#include "debugging/etLogger.h"
+#include "osal/etTime.h"
+
static char* prefixes[] = {
"E: ",
"W: ",
diff --git a/runtime/org.eclipse.etrice.runtime.c/src/common/runtime/etRuntime.c b/runtime/org.eclipse.etrice.runtime.c/src/common/runtime/etRuntime.c
index 432e31f6b..5b5915e4a 100644
--- a/runtime/org.eclipse.etrice.runtime.c/src/common/runtime/etRuntime.c
+++ b/runtime/org.eclipse.etrice.runtime.c/src/common/runtime/etRuntime.c
@@ -12,6 +12,8 @@
*
*******************************************************************************/
+#include <stdlib.h>
+#include <string.h>
#include "runtime/etRuntime.h"
#include "debugging/etMSCLogger.h"
diff --git a/runtime/org.eclipse.etrice.runtime.c/src/platforms/MT_POSIX_GENERIC_GCC/etDatatypes.h b/runtime/org.eclipse.etrice.runtime.c/src/platforms/MT_POSIX_GENERIC_GCC/etDatatypes.h
index 8e1787558..7e72f428a 100644
--- a/runtime/org.eclipse.etrice.runtime.c/src/platforms/MT_POSIX_GENERIC_GCC/etDatatypes.h
+++ b/runtime/org.eclipse.etrice.runtime.c/src/platforms/MT_POSIX_GENERIC_GCC/etDatatypes.h
@@ -31,6 +31,7 @@
#include <unistd.h>
#include <signal.h>
#if __GNUC__ <= 4
+ /* in newer versions this header isn't needed explicitly */
#include <bits/siginfo.h>
#endif
#include <time.h>

Back to the top