Hi, hotplug package is seriously broken and won't work on POSIX/SUSv3 compilant /bin/sh shells. $ echo $((0xff)) ksh: 0xff: bad number `0xff' There is a lot of hex to dec conversions using bash only function in hotplug, example: echo $((0xff)) Under ksh (pdksh) $ echo $((0xff)) ksh: 0xff: bad number `0xff' There is more portable version hex=0xff echo "$((16#`echo "$hex" | sed -e 's#^0x##g'`))" it works well on zsh, pdksh, bash in their enhaced mode but for example on pdksh run in sh mode it overflows - example: [arekm@mobarm arekm]$ echo $((16#ff)) 255 [arekm@mobarm arekm]$ echo $((16#ffffffff)) -1 pdksh run as pdksh works though. There are two solutions known to me right now: - first, very easy - #!/bin/bash instead of #!/bin/sh in these scripts - second working, POSIX/SUSv3 compilant but much slower; use awk for conversions (see attached patch). Any other known fast and portable hex to dec conversions? ps. using hex2dec() function regardles of choosen conversion method would be nice - it would allow easy way to change the way of doing conversion + it explicitly says where hex number should occur -- Arkadiusz Mi¶kiewicz CS at FoE, Wroclaw University of Technology arekm.pld-linux.org, 1024/3DB19BBD, JID: arekm.jabber.org, PLD/Linux