Project

General

Profile

Actions

Bug #5332

closed

cleanup gcc warning for cmd/fdformat

Added by Igor Kozhukhov over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Category:
-
Start date:
2014-11-14
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
needs-triage
Gerrit CR:
External Bug:

Description

+ /usr/gcc/4.8/bin/gcc -fident -finline -fno-inline-functions -fno-builtin -fno-asm -fdiagnostics-show-option -nodefaultlibs -D__sun -fno-strict-aliasing -fno-unit-at-a-time -fno-optimize-sibling-calls -O2 -m64 -mtune=opteron -Ui386 -U__i386 -Wall -Wextra -Werror -Wno-missing-braces -Wno-sign-compare -Wno-unknown-pragmas -Wno-unused-parameter -Wno-missing-field-initializers -Wno-array-bounds -Wno-unused-local-typedefs -std=gnu89 -fno-inline-small-functions -fno-inline-functions-called-once -fno-ipa-cp -DTEXT_DOMAIN="SUNW_OST_OSCMD" -D_TS_ERRNO -I/myshare/builds/ssd02/builds/dilos-illumos.lx/proto/root_i386/usr/include -Wl,-Bdirect -Wl,-M/myshare/builds/ssd02/builds/dilos-illumos.lx/usr/src/common/mapfiles/common/map.noexstk -Wl,-M/myshare/builds/ssd02/builds/dilos-illumos.lx/usr/src/common/mapfiles/common/map.pagealign -Wl,-M/myshare/builds/ssd02/builds/dilos-illumos.lx/usr/src/common/mapfiles/common/map.noexdata -o fdformat ./fdformat.c -L/myshare/builds/ssd02/builds/dilos-illumos.lx/proto/root_i386/lib/amd64 -L/myshare/builds/ssd02/builds/dilos-illumos.lx/proto/root_i386/usr/lib/amd64 -lvolmgt -lc 
./fdformat.c: In function 'format_diskette':
./fdformat.c:819:5: error: suggest explicit braces to avoid ambiguous 'else' [-Werror=parentheses]
  if (!(q_flag && f_flag))
     ^
./fdformat.c:475:16: error: variable 'fcmd_fmt' set but not used [-Werror=unused-but-set-variable]
  struct fd_cmd fcmd_fmt = {
                ^
./fdformat.c: In function 'valid_DOS_boot':
./fdformat.c:1461:2: error: suggest parentheses around assignment used as truth value [-Werror=parentheses]
  if (err = stat(bootfile, &status)) {
  ^
cc1: all warnings being treated as errors
*** Error code 1

Actions #1

Updated by Igor Kozhukhov over 8 years ago

  • % Done changed from 0 to 90
Actions #2

Updated by Electric Monk over 8 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 90 to 100

git commit a388614e98609b492a4937e6bf8bfdf340c6ba27

commit  a388614e98609b492a4937e6bf8bfdf340c6ba27
Author: Igor Kozhukhov <ikozhukhov@gmail.com>
Date:   2014-11-19T21:08:26.000Z

    5332 cleanup gcc warning for cmd/fdformat
    Reviewed by: Gary Mills <gary_mills@fastmail.fm>
    Reviewed by: Keith Wesolowski <keith.wesolowski@joyent.com>
    Reviewed by: Andy Stormont <astormont@racktopsystems.com>
    Reviewed by: Marcel Telka <marcel@telka.sk>
    Reviewed by: Garrett D'Amore <garrett@damore.org>
    Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
    Approved by: Robert Mustacchi <rm@joyent.com>

Actions

Also available in: Atom PDF