From 2a2a7c2d362f796d239f239f9f49cb16079dd713 Mon Sep 17 00:00:00 2001 From: Holger Vogt Date: Sat, 15 Dec 2018 10:36:09 +0100 Subject: [PATCH] sharedspice.c, NS Windows, use only POSIX compliant snprintf make OldAn a zero terminated string --- src/sharedspice.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/sharedspice.c b/src/sharedspice.c index 1932d7303..42c2cd3ab 100644 --- a/src/sharedspice.c +++ b/src/sharedspice.c @@ -148,10 +148,6 @@ static bool cont_condition; #include "misc/ivars.h" #include "frontend/resource.h" #include "frontend/com_measure2.h" -#ifdef _MSC_VER -#include -#define snprintf _snprintf -#endif #include "frontend/outitf.h" #include "ngspice/memory.h" #include "frontend/com_measure2.h" @@ -435,7 +431,7 @@ sighandler_sharedspice(int num) /* create a suspended thread tid2 that is activated when bg_run has finished. It executes the .control commands. If the arguemnt is NULL, the thread is - stated with the existing controls (e.g. for command 'reset'. */ + started with the existing controls (e.g. during command 'reset'. */ void exec_controls(wordlist *newcontrols) { @@ -1635,6 +1631,8 @@ void SetAnalyse( if (nostatuswanted) return; + OldAn[0] = '\0'; + if ((DecaPercent == OldPercent) && !strcmp(OldAn, Analyse)) return;