1. 28 12月, 2010 3 次提交
  2. 23 12月, 2010 2 次提交
  3. 22 12月, 2010 3 次提交
  4. 20 12月, 2010 3 次提交
  5. 18 12月, 2010 1 次提交
  6. 17 12月, 2010 1 次提交
  7. 16 12月, 2010 15 次提交
  8. 08 12月, 2010 2 次提交
  9. 01 12月, 2010 3 次提交
  10. 23 11月, 2010 2 次提交
  11. 22 11月, 2010 3 次提交
  12. 21 11月, 2010 1 次提交
    • J
      Input: serio HIL MLC - don't deref null, don't leak and return proper error · 39de5210
      Jesper Juhl 提交于
      While reviewing various users of kernel memory allocation functions I came
      across drivers/input/serio/hil_mlc.c::hil_mlc_register() and noticed that:
      
       - it calls kzalloc() but fails to check for a NULL return before use.
       - it makes several allocations and if one fails it doesn't free the
         previous ones.
       - It doesn't return -ENOMEM in the failed memory allocation case (it just
         crashes).
      
      This patch corrects all of the above and also reworks the only caller of
      this function that I could find
      (drivers/input/serio/hp_sdc_mlc.c::hp_sdc_mlc_out()) so that it now checks
      the return value of hil_mlc_register() and properly propagates it on
      failure and I also restructured the code to remove some labels and goto's
      to make it, IMHO nicer to read.
      Signed-off-by: NJesper Juhl <jj@chaosbits.net>
      Tested-by: NHelge Deller <deller@gmx.de>
      Acked-by: NHelge Deller <deller@gmx.de>
      Signed-off-by: NDmitry Torokhov <dtor@mail.ru>
      39de5210
  13. 20 11月, 2010 1 次提交