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