Format string bug in update-rc.d script

Bug #781873 reported by Emanuel Bronshtein
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
sysvinit (Ubuntu)
Triaged
Low
Unassigned

Bug Description

Binary package hint: sysvinit

/usr/sbin/update-rc.d and /usr/sbin/update-rc.d-insserv scripts have format string bug .

test case :
emanuel@emanuel-desktop /tmp>>touch bug%nf
emanuel@emanuel-desktop /tmp>>update-rc.d "../../tmp/bug%nf" start
Modification of a read-only value attempted at /usr/sbin/update-rc.d line 187.
emanuel@emanuel-desktop /tmp>>update-rc.d "../../tmp/bug%nf" remove
Modification of a read-only value attempted at /usr/sbin/update-rc.d line 82.

the problem is here :
printf STDERR "update-rc.d: warning: $initdscript missing LSB information\n";
printf STDERR "update-rc.d: $initd/$bn exists during rc.d purge (use -f to force)\n";

fix can be using print instead or add format %s to printf .
same bug exist in update-rc.d-insserv command from insserv package .

Steve Langasek (vorlon)
Changed in sysvinit (Ubuntu):
status: New → Triaged
importance: Undecided → Low
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.