Michael Stefaniuc : oleaut32: Do not cast NULL.
Alexandre Julliard
julliard at winehq.org
Mon Nov 3 09:06:58 CST 2008
Module: wine
Branch: master
Commit: 25f33cb0bc7f9745c0923a576b677f220443fbd4
URL: http://source.winehq.org/git/wine.git/?a=commit;h=25f33cb0bc7f9745c0923a576b677f220443fbd4
Author: Michael Stefaniuc <mstefani at redhat.de>
Date: Sun Nov 2 00:21:15 2008 +0100
oleaut32: Do not cast NULL.
---
dlls/oleaut32/olepicture.c | 4 +---
dlls/oleaut32/ungif.c | 12 ++++++------
2 files changed, 7 insertions(+), 9 deletions(-)
diff --git a/dlls/oleaut32/olepicture.c b/dlls/oleaut32/olepicture.c
index 93b932f..498ee53 100644
--- a/dlls/oleaut32/olepicture.c
+++ b/dlls/oleaut32/olepicture.c
@@ -1610,9 +1610,7 @@ succ:
end:
if(png_ptr)
- ppng_destroy_read_struct(&png_ptr,
- (info_ptr ? &info_ptr : (png_infopp) NULL),
- (png_infopp)NULL);
+ ppng_destroy_read_struct(&png_ptr, info_ptr ? &info_ptr : NULL, NULL);
HeapFree(GetProcessHeap(), 0, row_pointers);
HeapFree(GetProcessHeap(), 0, pngdata);
return ret;
diff --git a/dlls/oleaut32/ungif.c b/dlls/oleaut32/ungif.c
index 9cb5693..79bad60 100644
--- a/dlls/oleaut32/ungif.c
+++ b/dlls/oleaut32/ungif.c
@@ -148,16 +148,16 @@ MakeMapObject(int ColorCount,
/*** FIXME: Our ColorCount has to be a power of two. Is it necessary to
* make the user know that or should we automatically round up instead? */
if (ColorCount != (1 << BitSize(ColorCount))) {
- return ((ColorMapObject *) NULL);
+ return NULL;
}
Object = ungif_alloc(sizeof(ColorMapObject));
- if (Object == (ColorMapObject *) NULL) {
- return ((ColorMapObject *) NULL);
+ if (Object == NULL) {
+ return NULL;
}
Object->Colors = ungif_calloc(ColorCount, sizeof(GifColorType));
- if (Object->Colors == (GifColorType *) NULL) {
+ if (Object->Colors == NULL) {
return NULL;
}
@@ -413,9 +413,9 @@ DGifGetImageDesc(GifFileType * GifFile) {
return GIF_ERROR;
}
}
- sp->RasterBits = (unsigned char *)NULL;
+ sp->RasterBits = NULL;
sp->ExtensionBlockCount = 0;
- sp->ExtensionBlocks = (ExtensionBlock *) NULL;
+ sp->ExtensionBlocks = NULL;
GifFile->ImageCount++;
More information about the wine-cvs
mailing list