Merge branch 'akpm' (patches from Andrew)
[linux-2.6-microblaze.git] / sound / soc / codecs / cros_ec_codec.c
index c4772f8..a201d65 100644 (file)
@@ -94,7 +94,7 @@ static int send_ec_host_command(struct cros_ec_device *ec_dev, uint32_t cmd,
        if (ret < 0)
                goto error;
 
-       if (insize)
+       if (in && insize)
                memcpy(in, msg->data, insize);
 
        ret = 0;