diff options
author | Bill Pemberton <wfp5p@virginia.edu> | 2010-05-05 15:27:33 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-05-11 11:36:13 -0700 |
commit | 80d11b2ae26543656f7226b44ed9d6a184766e85 (patch) | |
tree | a5eba69fbddf85565eb4fc8d7a1b4276a014340a /drivers/staging/hv/Connection.c | |
parent | 8cad0af9a1a1882cd00f12f8f7c79690f563b1d7 (diff) |
Staging: hv: test return value of osd_WaitEventCreate()
The return value of osd_WaitEventCreate() was not examined in some
places.
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>
Diffstat (limited to 'drivers/staging/hv/Connection.c')
-rw-r--r-- | drivers/staging/hv/Connection.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/staging/hv/Connection.c b/drivers/staging/hv/Connection.c index 1e4111412ab..e590eb4b6e7 100644 --- a/drivers/staging/hv/Connection.c +++ b/drivers/staging/hv/Connection.c @@ -98,6 +98,11 @@ int VmbusConnect(void) } msgInfo->WaitEvent = osd_WaitEventCreate(); + if (!msgInfo->WaitEvent) { + ret = -ENOMEM; + goto Cleanup; + } + msg = (struct vmbus_channel_initiate_contact *)msgInfo->Msg; msg->Header.MessageType = ChannelMessageInitiateContact; |