[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [PATCH 4/4] Page80/83 data is optional
Check for non-NULL before attempting to free SCSI override data. Signed-off-by: Owen Smith <owen.smith@xxxxxxxxxx> --- src/xenvbd/frontend.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/xenvbd/frontend.c b/src/xenvbd/frontend.c index d7b2e66..f834cac 100644 --- a/src/xenvbd/frontend.c +++ b/src/xenvbd/frontend.c @@ -1368,11 +1368,13 @@ FrontendDisconnect( Frontend->NumQueues = 0; - Base64Free(Frontend->Page80.Data); + if (Frontend->Page80.Data) + Base64Free(Frontend->Page80.Data); Frontend->Page80.Data = NULL; Frontend->Page80.Size = 0; - Base64Free(Frontend->Page83.Data); + if (Frontend->Page83.Data) + Base64Free(Frontend->Page83.Data); Frontend->Page83.Data = NULL; Frontend->Page83.Size = 0; } @@ -1970,11 +1972,13 @@ FrontendDestroy( Trace("Target[%d] @ (%d) =====>\n", TargetId, KeGetCurrentIrql()); - Base64Free(Frontend->Page80.Data); + if (Frontend->Page80.Data) + Base64Free(Frontend->Page80.Data); Frontend->Page80.Data = NULL; Frontend->Page80.Size = 0; - Base64Free(Frontend->Page83.Data); + if (Frontend->Page83.Data) + Base64Free(Frontend->Page83.Data); Frontend->Page83.Data = NULL; Frontend->Page83.Size = 0; -- 2.31.1.windows.1
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |