On 2 June 2015 at 13:48, Karel Zak <kzak@xxxxxxxxxx> wrote: > On Sun, Feb 22, 2015 at 02:42:06PM +0000, Sami Kerola wrote: >> git://github.com/kerolasa/lelux-utiliteetit.git rtcwake > > I have reviewed > > https://github.com/kerolasa/lelux-utiliteetit/commits/rtcwake2 > > and commented by github line notes. Cheers. I left the rtcwake2 untouched, so that comments can be read until final merge. Some comments to comment. > https://github.com/kerolasa/lelux-utiliteetit/commit/0358a2cec1f55c4a723cb55c4da7ea201d2acb68#diff-40ed35508632e222c29a58eba03a4271L374 Type is changed, but I left the while loop as is. It looks nicer to me. Besides the get_mode() changes later in patch set again. > https://github.com/kerolasa/lelux-utiliteetit/commit/0358a2cec1f55c4a723cb55c4da7ea201d2acb68#diff-40ed35508632e222c29a58eba03a4271L510 Well, that was dumb issue. Thank you pointing it out. > https://github.com/kerolasa/lelux-utiliteetit/commit/cca324d3360535f0d990f7e696ebfd093b725c9c#diff-40ed35508632e222c29a58eba03a4271L317 skip_fline() is added to strutils.h and used the way as requested. > https://github.com/kerolasa/lelux-utiliteetit/commit/d8c827a711e6e2d34ce01dc460d98c4a3759e04a#diff-40ed35508632e222c29a58eba03a4271L501 So do I. > https://github.com/kerolasa/lelux-utiliteetit/commit/81f7e2a6fc5870ebfcb078e0973b0d9a57cae205#diff-40ed35508632e222c29a58eba03a4271R390 Done a bit differently with xstrdup(), so that I there's always an allocation and free()'ing is simple. > https://github.com/kerolasa/lelux-utiliteetit/commit/b9d49884a250e33c55f92e47d0e1b72e33598998#diff-40ed35508632e222c29a58eba03a4271L601 The strv.h is now used. I hope the code is more elegant, but to be honest improvement might not be quite as nice as hoped. Notice that the ctl->possible_modes is populated only when --list-modes and --mode are in use, so I don't see any point running get_sys_power_states() at early of execution. BTW the new rtcwake3 has new commit. Just a simple fix. https://github.com/kerolasa/lelux-utiliteetit/commit/a08b7936598fdc462c516331c4b91d331d7508ff rtcwake: fix valgrind warning -- Sami Kerola http://www.iki.fi/kerolasa/ -- To unsubscribe from this list: send the line "unsubscribe util-linux" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html