]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/usb/gadget/serial.c
[PATCH] USB: kfree cleanup for drivers/usb/* - no need to check for NULL
[linux-2.6-omap-h63xx.git] / drivers / usb / gadget / serial.c
index 2af3f785d5a11c92926b7891c486f7fb762501a3..f1762ed6db6394aefd5340ddabc8692f56d89fbc 100644 (file)
@@ -2312,9 +2312,8 @@ static struct gs_buf *gs_buf_alloc(unsigned int size, int kmalloc_flags)
  */
 void gs_buf_free(struct gs_buf *gb)
 {
-       if (gb != NULL) {
-               if (gb->buf_buf != NULL)
-                       kfree(gb->buf_buf);
+       if (gb) {
+               kfree(gb->buf_buf);
                kfree(gb);
        }
 }