diff options
Diffstat (limited to 'source3')
-rw-r--r-- | source3/printing/printing.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source3/printing/printing.c b/source3/printing/printing.c index 7ffded8e91..00df859e0a 100644 --- a/source3/printing/printing.c +++ b/source3/printing/printing.c @@ -714,7 +714,10 @@ static BOOL parse_lpq_entry(int snum,char *line, #endif /* We don't want the newline in the status message. */ - line[strcspn(line,"\n")] = (char)NULL; + { + char *p = strchr(line,'\n'); + if (p) *p = 0; + } if (status && !ret) { |