From d52ea1c369f9c3838d6b26f9f26b762003d8414b Mon Sep 17 00:00:00 2001 From: kevin Date: Sat, 28 Sep 2013 12:28:54 -0700 Subject: [PATCH] cmScore.c : Fixed apparent bug where p->sets[i].symArray[] was assigned twice and p->sets[i].costSymArray[] was not assigned at all in _cmScProcSets(). Added a printf() which mysteriously prevents an OS-X Crash in _cmScProcSets(). --- app/cmScore.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/cmScore.c b/app/cmScore.c index c0429dd..4c67749 100644 --- a/app/cmScore.c +++ b/app/cmScore.c @@ -800,14 +800,18 @@ cmScRC_t _cmScProcSets( cmSc_t* p ) { if( cmSymTblIsValid(p->stH) ) { + + // THIS PRINTF PREVENTS CRASH ON OSX ??????? printf("PROCSET:%i %s\n",p->sets[i].varId,ep->label); + + p->sets[i].symArray[j] = cmSymTblRegisterFmt(p->stH,"%c-%s", _cmScVarIdToChar(p->sets[i].varId),ep->label); p->sets[i].costSymArray[j] = cmSymTblRegisterFmt(p->stH,"c%c-%s",_cmScVarIdToChar(p->sets[i].varId),ep->label); } else { p->sets[i].symArray[j] = cmInvalidId; - p->sets[i].symArray[j] = cmInvalidId; + p->sets[i].costSymArray[j] = cmInvalidId; } p->sets[i].sectArray[j] = sp;