- Fixed documentation typos
- In support of HMsec, allow the count command in countsec to run without a preset parameter. If this is missing the old, stored preset is used. - Removed a check which causes initialisation of the HM from a batch file fail for POLDI - fixed @nl@ encoding of \n problem with certain kinds of batch files generated by GTSE - Fixed a bug with summing on hitsmemsec. nxdataset now uses 64 bit int for dimensions. - Fixed motorsec to remove itself properly from a parent when linked. Please note that there is still the limitation that a second generation motor can only be linked once in a Hipadaba tree - Extended subsampling a HM for second generation HM - Added a hscriptnotify. This calls a script on the update of a node - POLDI has been rebuilt, chnages to data file writing - For testing, sinqhttopt now understands a special command, byteswapoff, which switches off byte swapping. Required when the HM ius run on an Intel box. SKIPPED: psi/polterwrite.c psi/sinqhttpopt.c
This commit is contained in:
29
exebuf.c
29
exebuf.c
@@ -91,13 +91,39 @@ static char *locateName(char *filename)
|
||||
}
|
||||
return filename;
|
||||
}
|
||||
/*----------------------------------------------------------------------
|
||||
If this is MOUNTAINBATCH file, replace ocurrences of @nl@ with \n
|
||||
------------------------------------------------------------------------*/
|
||||
static void fixMountainBatch(pExeBuf self)
|
||||
{
|
||||
char *pPtr, *pData, *pNL;
|
||||
|
||||
pPtr = GetCharArray(self->bufferContent);
|
||||
if(strstr(pPtr, "#MOUNTAINBATCH") != pPtr){
|
||||
/*
|
||||
nothing to do
|
||||
*/
|
||||
return;
|
||||
}
|
||||
pData = strdup(pPtr);
|
||||
DynStringClear(self->bufferContent);
|
||||
pPtr = pData;
|
||||
while((pNL = strstr(pPtr,"@nl@")) != NULL){
|
||||
*pNL = '\n';
|
||||
*(pNL+1) = '\0';
|
||||
DynStringConcat(self->bufferContent, pPtr);
|
||||
pPtr = pNL +4;
|
||||
}
|
||||
DynStringConcat(self->bufferContent,pPtr);
|
||||
free(pData);
|
||||
|
||||
}
|
||||
/*-----------------------------------------------------------------------*/
|
||||
int exeBufLoad(pExeBuf self, char *filename)
|
||||
{
|
||||
char line[256], *pPtr;
|
||||
FILE *fd = NULL;
|
||||
int status, idx;
|
||||
int status, idx, gtsebatch = 0;
|
||||
|
||||
assert(self);
|
||||
fd = fopen(filename, "r");
|
||||
@@ -128,6 +154,7 @@ int exeBufLoad(pExeBuf self, char *filename)
|
||||
free(self->name);
|
||||
}
|
||||
self->name = strdup(locateName(filename));
|
||||
fixMountainBatch(self);
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user