Staging: hv: remove ASSERT()s in ChannelMgt.c

Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
Bill Pemberton 2010-05-05 15:27:31 -04:00 committed by Greg Kroah-Hartman
parent 1e19c05443
commit 75910f236a

View file

@ -753,9 +753,15 @@ int VmbusChannelRequestOffers(void)
msgInfo = kmalloc(sizeof(*msgInfo) +
sizeof(struct vmbus_channel_message_header),
GFP_KERNEL);
ASSERT(msgInfo != NULL);
if (!msgInfo)
return -ENOMEM;
msgInfo->WaitEvent = osd_WaitEventCreate();
if (!msgInfo->WaitEvent) {
kfree(msgInfo);
return -ENOMEM;
}
msg = (struct vmbus_channel_message_header *)msgInfo->Msg;
msg->MessageType = ChannelMessageRequestOffers;