Hi, On Friday 24 March 2006 20:13, Stefan Rompf wrote: > recently I patched my 2.6.16 kernel to use uswsusp. Nice work, but when I > installed /usr/local/sbin/suspend into the Suse 9.3 powermanagement scripts, > I've stumbled over a bad interaction: powersaved closes all filedescriptors > before calling scripts. suspend then opens snapshot and swap device, > allocating file descriptors 0 and 1, but printfs() afterwards. Luckily, I did > not lose any data. > > For robustness, suspend must make sure that these fds are open. Simple patch > to achieve this is attached. It loses the descriptors, but I don't think > that's an issue for the short running program. Thanks a lot for the patch, I'll have a look at it shortly. BTW, it follows from what you said that you compiled suspend on SuSE 9.3. Was it on i386? Rafael