mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-05-03 03:10:04 +02:00
merge conflict resolved
This commit is contained in:
parent
b7805ae0d4
commit
96ec3b2123
Binary file not shown.
@ -514,6 +514,30 @@ int readConfigFile() {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// removing leading spaces
|
||||||
|
if (line[0] == ' ' || line[0] == '\t') {
|
||||||
|
int len = strlen(line);
|
||||||
|
// find first valid character
|
||||||
|
int i = 0;
|
||||||
|
for (i = 0; i < len; ++i) {
|
||||||
|
if (line[i] != ' ' && line[i] != '\t') {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// ignore the line full of spaces (last char \n)
|
||||||
|
if (i >= len - 1) {
|
||||||
|
LOG(logDEBUG1, ("Ignoring line full of spaces\n"));
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
// copying only valid char
|
||||||
|
char temp[LZ];
|
||||||
|
memset(temp, 0, LZ);
|
||||||
|
memcpy(temp, line + i, strlen(line) - i);
|
||||||
|
memset(line, 0, LZ);
|
||||||
|
memcpy(line, temp, strlen(temp));
|
||||||
|
LOG(logDEBUG1, ("Removing leading spaces.\n"));
|
||||||
|
}
|
||||||
|
|
||||||
LOG(logDEBUG1, ("Command to process: (size:%d) %.*s\n", strlen(line), strlen(line) -1, line));
|
LOG(logDEBUG1, ("Command to process: (size:%d) %.*s\n", strlen(line), strlen(line) -1, line));
|
||||||
memset(command, 0, LZ);
|
memset(command, 0, LZ);
|
||||||
|
|
||||||
|
Binary file not shown.
@ -53,6 +53,30 @@ int loadDefaultPattern(char* fname) {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// removing leading spaces
|
||||||
|
if (line[0] == ' ' || line[0] == '\t') {
|
||||||
|
int len = strlen(line);
|
||||||
|
// find first valid character
|
||||||
|
int i = 0;
|
||||||
|
for (i = 0; i < len; ++i) {
|
||||||
|
if (line[i] != ' ' && line[i] != '\t') {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// ignore the line full of spaces (last char \n)
|
||||||
|
if (i >= len - 1) {
|
||||||
|
LOG(logDEBUG1, ("Ignoring line full of spaces\n"));
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
// copying only valid char
|
||||||
|
char temp[LZ];
|
||||||
|
memset(temp, 0, LZ);
|
||||||
|
memcpy(temp, line + i, strlen(line) - i);
|
||||||
|
memset(line, 0, LZ);
|
||||||
|
memcpy(line, temp, strlen(temp));
|
||||||
|
LOG(logDEBUG1, ("Removing leading spaces.\n"));
|
||||||
|
}
|
||||||
|
|
||||||
LOG(logDEBUG1, ("Command to process: (size:%d) %.*s\n",
|
LOG(logDEBUG1, ("Command to process: (size:%d) %.*s\n",
|
||||||
strlen(line), strlen(line) -1, line));
|
strlen(line), strlen(line) -1, line));
|
||||||
memset(command, 0, LZ);
|
memset(command, 0, LZ);
|
||||||
|
@ -9,4 +9,5 @@
|
|||||||
#define APIJUNGFRAU 0x200409
|
#define APIJUNGFRAU 0x200409
|
||||||
#define APIMYTHEN3 0x200428
|
#define APIMYTHEN3 0x200428
|
||||||
#define APIGOTTHARD2 0x200429
|
#define APIGOTTHARD2 0x200429
|
||||||
#define APIMOENCH 0x200428
|
|
||||||
|
#define APIMOENCH 0x200429
|
||||||
|
Loading…
x
Reference in New Issue
Block a user