fsx: add optional logid prefix to log messages
authorAmir Goldstein <amir73il@gmail.com>
Thu, 7 Sep 2017 07:26:35 +0000 (10:26 +0300)
committerEryu Guan <eguan@redhat.com>
Fri, 8 Sep 2017 03:42:02 +0000 (11:42 +0800)
commitbd918dff012b570f212bdb4e0febea7799ebeca3
treef7275c4edab7c2e7e0a71a586760aa52d9f0fd01
parent3582f7b1bf009965968f5296ddf64c2abca8dc29
fsx: add optional logid prefix to log messages

When redirecting the intermixed output of several fsx processes
to a single output file, it is usefull to prefix debug log messages
with a log id. Use fsx -j <logid> to define the log messages prefix.

Fix implementation of prt() function to avoid using a temp buffer
and convert some more printf() calls to use ptr() instead.

Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
ltp/fsx.c