Bug 1708163

Summary: tests: fix bug-1319374.c compile warnings.
Product: [Community] GlusterFS Reporter: Ravishankar N <ravishankar>
Component: testsAssignee: Ravishankar N <ravishankar>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: mainlineCC: bugs
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-05-10 14:54:50 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ravishankar N 2019-05-09 09:19:59 UTC
Description of problem:

    tests: fix bug-1319374.c compile warnings.

    I was looking at a downstream failure of bug-1319374-THIS-crash.t when I
    saw the compiler was throwing a warning while running the test:

    tests/bugs/gfapi/bug-1319374.c:17:61: warning: implicit declaration of function ‘strerror’; did you mean ‘perror’? [-Wimplicit-function-declaration]
             fprintf(stderr, "\nglfs_new: returned NULL (%s)\n", strerror(errno));
                                                                 ^~~~~~~~
                                                                 perror

    So I compiled the .c with -Wall and saw a lot many more warnings, all
    due of a missing header.

Comment 1 Worker Ant 2019-05-09 09:23:09 UTC
REVIEW: https://review.gluster.org/22691 (tests: fix bug-1319374.c compile warnings.) posted (#1) for review on master by Ravishankar N

Comment 2 Worker Ant 2019-05-10 14:54:50 UTC
REVIEW: https://review.gluster.org/22691 (tests: fix bug-1319374.c compile warnings.) merged (#2) on master by Raghavendra Talur