t/read-to-pipe-async: Complain if option -f is specified multiple times
authorBart Van Assche <bvanassche@acm.org>
Sat, 4 Jan 2020 22:10:47 +0000 (14:10 -0800)
committerBart Van Assche <bvanassche@acm.org>
Sat, 4 Jan 2020 22:39:41 +0000 (14:39 -0800)
commita06aec04b3422d8ec63250e3ac56bbf526bc41b0
tree4fd6fb16a51b3c0f87a1c15e4f4fd209a0f6d2f7
parenta404c9bd161ec5d23c60fa661c9737e303e3cd65
t/read-to-pipe-async: Complain if option -f is specified multiple times

This patch fixes the following Coverity complaint:

CID 280676:  Resource leaks  (RESOURCE_LEAK)
Overwriting "file" in "file = strdup(optarg)" leaks the storage that "file"
points to.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
t/read-to-pipe-async.c