Project

General

Profile

Bug #12201

Enable smatch for zonestat and zonestatd

Added by Marcel Telka 11 months ago. Updated 10 months ago.

Status:
Closed
Priority:
Low
Assignee:
Category:
cmd - userland programs
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:

Description

smatch currently reports one issue for zonestat and one for zonestatd:

zonestat.c:2361 main() warn: maybe use && instead of &
zonestatd.c:3878 zsd_usage_cache_update() warn: inconsistent indenting

Once the fix for #12193 (inconsistent indenting in zonestatd.c) is integrated we could easily fix the other one (in zonestat) and enable smatch for both zonestat and zonestatd.


Related issues

Related to illumos gate - Bug #12193: zonestatd: Wrong indentation in zsd_usage_cache_update()ClosedMarcel Telka

Actions
#1

Updated by Marcel Telka 11 months ago

  • Related to Bug #12193: zonestatd: Wrong indentation in zsd_usage_cache_update() added
#2

Updated by Marcel Telka 10 months ago

Testing Done

Nightly completed successfully.

Without the fix:

$ /usr/bin/zonestat -P resource 2>&1 | grep Error
zonestat: Error: -P requires -p
$

With the fix:

$ proto/root_i386/usr/bin/zonestat -P resource 2>&1 | grep Error
zonestat: Error: -P requires -p
$
#4

Updated by Marcel Telka 10 months ago

  • Status changed from In Progress to Pending RTI
#5

Updated by Electric Monk 10 months ago

  • Status changed from Pending RTI to Closed
  • % Done changed from 0 to 100

git commit ecaa37affc4da0ba0f1331de875432d68cf70a80

commit  ecaa37affc4da0ba0f1331de875432d68cf70a80
Author: Marcel Telka <marcel@telka.sk>
Date:   2020-01-27T14:47:00.000Z

    12201 Enable smatch for zonestat and zonestatd
    Reviewed by: C Fraire <seeemef@mac.com>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF