[bug-notifications] [cswclassutils 0003785]: autoenable_specificdaemonname probably doesn't work

Mantis Bug Tracker noreply at opencsw.org
Wed Aug 12 11:29:14 CEST 2009


The following issue has been CLOSED 
====================================================================== 
http://www.opencsw.org/mantis/view.php?id=3785 
====================================================================== 
Reported By:                yann
Assigned To:                bonivart
====================================================================== 
Project:                    cswclassutils
Issue ID:                   3785
Category:                   regular use
Reproducibility:            have not tried
Severity:                   minor
Priority:                   normal
Status:                     closed
Resolution:                 open
Fixed in Version:           
====================================================================== 
Date Submitted:             2009-07-28 20:37 CEST
Last Modified:              2009-08-12 11:29 CEST
====================================================================== 
Summary:                    autoenable_specificdaemonname probably doesn't work
Description: 
Hi,

Just had a look at i.cswinitsmf trying to solve a bug reported on my
package, and I noticed the code used to evaluate
autoenable_specificdaemonname is probably wrong.

The code is:

  if [ "$autoenable_$service" = "no" ]; then
    daemon=no
  elif [ "$autoenable_$service" = "yes" ]; then
    daemon=yes
  fi

but sh consider there are two variables $autoenable_ and $service. 
$autoenable_ has never been set so it is "", so for exemple for opencsw sh
will replace "$autoenable_$service" by "cswopenssh".

You could instead do:

eval autoenable_service="\$autoenable_$service"

and replace $autoenable_$service by $autoenable_service


====================================================================== 

---------------------------------------------------------------------- 
 (0006559) bonivart (manager) - 2009-08-12 11:29
 http://www.opencsw.org/mantis/view.php?id=3785#c6559 
---------------------------------------------------------------------- 
Cswclassutils 1.18 released with fix.




More information about the bug-notifications mailing list