linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / net / bluetooth / cmtp / capi.c
index ab166b4..18910ff 100644 (file)
@@ -20,6 +20,7 @@
    SOFTWARE IS DISCLAIMED.
 */
 
+#include <linux/config.h>
 #include <linux/module.h>
 
 #include <linux/types.h>
 
 static struct cmtp_application *cmtp_application_add(struct cmtp_session *session, __u16 appl)
 {
-       struct cmtp_application *app = kzalloc(sizeof(*app), GFP_KERNEL);
+       struct cmtp_application *app = kmalloc(sizeof(*app), GFP_KERNEL);
 
        BT_DBG("session %p application %p appl %d", session, app, appl);
 
        if (!app)
                return NULL;
 
+       memset(app, 0, sizeof(*app));
+
        app->state = BT_OPEN;
        app->appl = appl;