From f1a05842735a057b97d97a275c1b3ab02453fadc Mon Sep 17 00:00:00 2001 From: Andrew Johnson Date: Tue, 3 Feb 2009 06:05:51 +0000 Subject: [PATCH] Fix gcc warnings. --- src/bpt/makeBpt.c | 4 ++-- src/libCom/error/errlog.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/bpt/makeBpt.c b/src/bpt/makeBpt.c index 26e91eea7..487319e75 100644 --- a/src/bpt/makeBpt.c +++ b/src/bpt/makeBpt.c @@ -71,8 +71,8 @@ static int getNumber(char **pbeg, double *value) static void errExit(char *pmessage) { - fprintf(stderr,pmessage); - fprintf(stderr,"\n"); + fprintf(stderr, "%s\n", pmessage); + fflush(stderr); exit(-1); } diff --git a/src/libCom/error/errlog.h b/src/libCom/error/errlog.h index 6c2462f67..f08d4a936 100644 --- a/src/libCom/error/errlog.h +++ b/src/libCom/error/errlog.h @@ -22,7 +22,7 @@ extern "C" { /* define errMessage with a macro so we can print the file and line number*/ #define errMessage(S, PM) \ - errPrintf(S, __FILE__, __LINE__, PM) + errPrintf(S, __FILE__, __LINE__, "%s", PM) /* epicsPrintf and epicsVprintf old versions of errlog routines*/ #define epicsPrintf errlogPrintf #define epicsVprintf errlogVprintf