From e7aee4d939c324c6a3090cb391500d7e1909bf30 Mon Sep 17 00:00:00 2001 From: Iztok Jeras <iztok.jeras@redpitaya.com> Date: ćšć, 08 10æ 2015 03:00:34 +0800 Subject: [PATCH] integer parser: updated tests to use snprintf for reference strings, started using C99 standard --- examples/test-tcp/main.c | 8 ++------ 1 files changed, 2 insertions(+), 6 deletions(-) diff --git a/examples/test-tcp/main.c b/examples/test-tcp/main.c index 2336165..3099899 100644 --- a/examples/test-tcp/main.c +++ b/examples/test-tcp/main.c @@ -44,6 +44,7 @@ #include <sys/ioctl.h> #include <errno.h> #include <arpa/inet.h> +#include <unistd.h> #include "scpi/scpi.h" #include "../common/scpi-def.h" @@ -63,7 +64,7 @@ int SCPI_Error(scpi_t * context, int_fast16_t err) { (void) context; // BEEP - fprintf(stderr, "**ERROR: %d, \"%s\"\r\n", (int32_t) err, SCPI_ErrorTranslate(err)); + fprintf(stderr, "**ERROR: %d, \"%s\"\r\n", (int16_t) err, SCPI_ErrorTranslate(err)); return 0; } @@ -73,11 +74,6 @@ } else { fprintf(stderr, "**CTRL %02x: 0x%X (%d)\r\n", ctrl, val, val); } - return SCPI_RES_OK; -} - -scpi_result_t SCPI_Test(scpi_t * context) { - fprintf(stderr, "**Test\r\n"); return SCPI_RES_OK; } -- Gitblit v1.9.1