Skip to content

Commit 0a3ba84

Browse files
Simplify statement of NULL path replacement
1 parent 3182c41 commit 0a3ba84

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

htstress.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -491,8 +491,8 @@ int main(int argc, char *argv[])
491491
outbufsize += rq ? strlen(rq) : 1;
492492

493493
outbuf = malloc(outbufsize);
494-
outbufsize = rq ? snprintf(outbuf, outbufsize, HTTP_REQUEST_FMT, rq, host)
495-
: snprintf(outbuf, outbufsize, HTTP_REQUEST_FMT, "/", host);
494+
outbufsize =
495+
snprintf(outbuf, outbufsize, HTTP_REQUEST_FMT, rq ? rq : "/", host);
496496

497497
ticks = max_requests / 10;
498498

0 commit comments

Comments
 (0)