Fix bug#30. Fix logging call from prev patch

remotes/origin/master-1.0.x
Gerardo Iglesias Galvan 16 years ago committed by Victor Julien
parent 988dc5520b
commit fae92f8d7b

@ -255,6 +255,11 @@ int DetectLoadSigFile(DetectEngineCtx *de_ctx, char *sig_file, int *sigs_tot) {
* to parse. */
}
/* Check if we have a trailing newline, and remove it */
len = strlen(line);
if (line[len - 1] == '\n') {
line[len - 1] = '\0';
}
/* Reset offset. */
offset = 0;
@ -265,7 +270,7 @@ int DetectLoadSigFile(DetectEngineCtx *de_ctx, char *sig_file, int *sigs_tot) {
SCLogDebug("signature %"PRIu32" loaded", sig->id);
good++;
} else {
SCLogDebug("Error parsing signature \"%s\" from file %s", line, sig_file);
SCLogError(SC_ERR_INVALID_SIGNATURE, "Error parsing signature \"%s\" from file %s", line, sig_file);
bad++;
}
}

Loading…
Cancel
Save