9966 svccfg cleanup crashes on empty manifestfiles property group

Review Request #1274 — Created Nov. 8, 2018 and submitted

citrus
illumos-gate
master
9966
d55a587...
general
9966 svccfg cleanup crashes on empty manifestfiles property group

before:

bloody# svccfg cleanup
bloody# svccfg -s filesystem/local delpg manifestfiles
bloody# svccfg -s filesystem/local addpg manifestfiles framework
bloody# svccfg cleanup
Delete service svc:/system/filesystem/local as there are no supporting manifests
zsh: IOT instruction (core dumped)  svccfg cleanup

after:

bloody:illumos:master% pfexec svccfg import /lib/svc/manifest/system/filesystem/local-fs.xml
bloody:illumos:master% svcadm refresh filesystem/local
bloody:illumos:master% svccfg cleanup
bloody:illumos:master%
bloody:illumos:master% svccfg -s filesystem/local delpg manifestfiles
bloody:illumos:master% svccfg -s filesystem/local addpg manifestfiles framework
bloody:illumos:master% ./svccfg cleanup
Delete service svc:/system/filesystem/local as there are no supporting manifests
bloody:illumos:master%
andy_js
  1. Ship It!
  2. 
      
domag02
  1. Ship It!
  2. 
      
tsoome
  1. Ok, the fix seems good. But I had the question, why such case was not discovered by compiler.... till I did look into Makefile

    CERRWARN +=     -_gcc=-Wno-unused-label
    CERRWARN +=     -_gcc=-Wno-implicit-function-declaration
    CERRWARN +=     -_gcc=-Wno-switch
    CERRWARN +=     -_gcc=-Wno-uninitialized
    CERRWARN +=     -_gcc=-Wno-unused-variable
    CERRWARN +=     -_gcc=-Wno-parentheses
    

    Shouldn't we remove those? There is quite a list of unuinitialized use cases and other issues hidden.

    1. I'll look at that as a follow up.

  2. 
      
citrus
Review request changed

Status: Closed (submitted)

Loading...