Hi Bastian,

Le 26/03/2014 20:25, Bastian Bittorf a écrit :
> * Jonas Gorski <[email protected]> [26.03.2014 20:18]:
>>> +proto_dhcpv6_renew() {
>>> +       local interface="$1"
>>> +       # SIGUSR1 forces odhcp6c to renew its lease
>>> +       proto_kill_command "$interface" 16
>>
>> SIGUSR1 is 16 only for mips; other arches use different values (see
>> e.g. 
>> <http://de.wikipedia.org/wiki/Signal_(Computer)#G.C3.A4ngige_UNIX-Signale>).
>>
> 
> yes, have this on my todo-list:
> the signal should be humanreadable e.g. 'SIGUSR1' and
> then translated to the specific value, e.g. in
> /lib/netifd/netifd-proto.sh
> 
> proto_kill_command()
> {
>       local signal="$2"       # e.g. USR1
>       local code="$( kill -l | grep " $signal" | cut -d')' -f1 )"
> 
>       ...
> }
> 
> can i send a patch or is this a bad idea?

The Busybox "kill" applet accepts named as well as numeric signals, i.e. "kill 
-USR1 <pid>" should work.

--
Michel

> 
> bye, bastian
> _______________________________________________
> openwrt-devel mailing list
> [email protected]
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
> 
_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to