? warnings Index: pixman/src/fbcompose.c =================================================================== RCS file: /cvs/cairo/cairo/pixman/src/fbcompose.c,v retrieving revision 1.2 diff -u -p -r1.2 fbcompose.c --- pixman/src/fbcompose.c 19 Aug 2005 01:46:30 -0000 1.2 +++ pixman/src/fbcompose.c 23 Aug 2005 12:02:47 -0000 @@ -585,7 +585,7 @@ static fetchProc fetchProcForPicture (Pi case PICT_a1: return fbFetch_a1; case PICT_g1: return fbFetch_g1; default: - return 0; + return NULL; } } @@ -1013,7 +1013,7 @@ static fetchPixelProc fetchPixelProcForP case PICT_a1: return fbFetchPixel_a1; case PICT_g1: return fbFetchPixel_g1; default: - return 0; + return NULL; } } @@ -1449,7 +1449,7 @@ static storeProc storeProcForPicture (Pi case PICT_a1: return fbStore_a1; case PICT_g1: return fbStore_g1; default: - return 0; + return NULL; } } @@ -1953,7 +1953,7 @@ fbCombineConjointXorU (CARD32 *dest, con static CombineFuncU fbCombineFuncU[] = { fbCombineClear, fbCombineSrcU, - 0, /* CombineDst */ + NULL, /* CombineDst */ fbCombineOverU, fbCombineOverReverseU, fbCombineInU, @@ -1965,11 +1965,11 @@ static CombineFuncU fbCombineFuncU[] = { fbCombineXorU, fbCombineAddU, fbCombineSaturateU, - 0, - 0, + NULL, + NULL, fbCombineClear, fbCombineSrcU, - 0, /* CombineDst */ + NULL, /* CombineDst */ fbCombineDisjointOverU, fbCombineSaturateU, /* DisjointOverReverse */ fbCombineDisjointInU, @@ -1979,13 +1979,13 @@ static CombineFuncU fbCombineFuncU[] = { fbCombineDisjointAtopU, fbCombineDisjointAtopReverseU, fbCombineDisjointXorU, - 0, - 0, - 0, - 0, + NULL, + NULL, + NULL, + NULL, fbCombineClear, fbCombineSrcU, - 0, /* CombineDst */ + NULL, /* CombineDst */ fbCombineConjointOverU, fbCombineConjointOverReverseU, fbCombineConjointInU, @@ -2574,7 +2574,7 @@ fbCombineConjointXorC (CARD32 *dest, CAR static CombineFuncC fbCombineFuncC[] = { fbCombineClearC, fbCombineSrcC, - 0, /* Dest */ + NULL, /* Dest */ fbCombineOverC, fbCombineOverReverseC, fbCombineInC, @@ -2586,11 +2586,11 @@ static CombineFuncC fbCombineFuncC[] = { fbCombineXorC, fbCombineAddC, fbCombineSaturateC, - 0, - 0, + NULL, + NULL, fbCombineClearC, /* 0x10 */ fbCombineSrcC, - 0, /* Dest */ + NULL, /* Dest */ fbCombineDisjointOverC, fbCombineSaturateC, /* DisjointOverReverse */ fbCombineDisjointInC, @@ -2600,13 +2600,13 @@ static CombineFuncC fbCombineFuncC[] = { fbCombineDisjointAtopC, fbCombineDisjointAtopReverseC, fbCombineDisjointXorC, /* 0x1b */ - 0, - 0, - 0, - 0, + NULL, + NULL, + NULL, + NULL, fbCombineClearC, fbCombineSrcC, - 0, /* Dest */ + NULL, /* Dest */ fbCombineConjointOverC, fbCombineConjointOverReverseC, fbCombineConjointInC, @@ -2619,7 +2619,7 @@ static CombineFuncC fbCombineFuncC[] = { }; -FbComposeFunctions composeFunctions = { +static FbComposeFunctions composeFunctions = { fbCombineFuncU, fbCombineFuncC, fbCombineMaskU @@ -2638,7 +2638,7 @@ static void fbFetchSolid(PicturePtr pict #ifdef PIXMAN_INDEXED_FORMATS miIndexedPtr indexed = (miIndexedPtr) pict->pFormat->index.devPrivate; #else - miIndexedPtr indexed = 0; + miIndexedPtr indexed = NULL; #endif fbGetDrawable (pict->pDrawable, bits, stride, bpp, xoff, yoff); @@ -2661,7 +2661,7 @@ static void fbFetch(PicturePtr pict, int #ifdef PIXMAN_INDEXED_FORMATS miIndexedPtr indexed = (miIndexedPtr) pict->pFormat->index.devPrivate; #else - miIndexedPtr indexed = 0; + miIndexedPtr indexed = NULL; #endif fbGetDrawable (pict->pDrawable, bits, stride, bpp, xoff, yoff); @@ -2903,7 +2903,7 @@ static void fbFetchTransformed(PicturePt #ifdef PIXMAN_INDEXED_FORMATS miIndexedPtr indexed = (miIndexedPtr) pict->pFormat->index.devPrivate; #else - miIndexedPtr indexed = 0; + miIndexedPtr indexed = NULL; #endif Bool projective = FALSE; @@ -3384,7 +3384,7 @@ static void fbStore(PicturePtr pict, int #ifdef PIXMAN_INDEXED_FORMATS miIndexedPtr indexed = (miIndexedPtr) pict->pFormat->index.devPrivate; #else - miIndexedPtr indexed = 0; + miIndexedPtr indexed = NULL; #endif fbGetDrawable (pict->pDrawable, bits, stride, bpp, xoff, yoff); @@ -3407,7 +3407,7 @@ static void fbStoreExternalAlpha(Picture #ifdef PIXMAN_INDEXED_FORMATS miIndexedPtr indexed = (miIndexedPtr) pict->pFormat->index.devPrivate; #else - miIndexedPtr indexed = 0; + miIndexedPtr indexed = NULL; #endif miIndexedPtr aindexed; @@ -3421,7 +3421,7 @@ static void fbStoreExternalAlpha(Picture #ifdef PIXMAN_INDEXED_FORMATS aindexed = (miIndexedPtr) pict->alphaMap->pFormat->index.devPrivate; #else - aindexed = 0; + aindexed = NULL; #endif ax = x; @@ -3452,10 +3452,10 @@ fbCompositeRect (const FbComposeData *da CARD32 *dest_buffer = src_buffer + data->width; int i; scanStoreProc store; - scanFetchProc fetchSrc = 0, fetchMask = 0, fetchDest = 0; + scanFetchProc fetchSrc = NULL, fetchMask = NULL, fetchDest = NULL; if (data->op == PIXMAN_OPERATOR_CLEAR) - fetchSrc = 0; + fetchSrc = NULL; else if (!data->src->pDrawable) { #ifdef PIXMAN_GRADIENTS if (data->src->pSourcePict) @@ -3497,7 +3497,7 @@ fbCompositeRect (const FbComposeData *da else fetchMask = fbFetchTransformed; } else { - fetchMask = 0; + fetchMask = NULL; } if (data->dest->alphaMap) { @@ -3508,7 +3508,7 @@ fbCompositeRect (const FbComposeData *da store = fbStore; } if (data->op == PIXMAN_OPERATOR_CLEAR || data->op == PIXMAN_OPERATOR_SRC) - fetchDest = 0; + fetchDest = NULL; if (fetchSrc && fetchMask && data->mask && data->mask->componentAlpha && PICT_FORMAT_RGB(data->mask->format_code)) { CARD32 *mask_buffer = dest_buffer + data->width; @@ -3544,8 +3544,8 @@ fbCompositeRect (const FbComposeData *da fetchMask(data->mask, data->xMask, data->yMask, data->width, dest_buffer); composeFunctions.combineMaskU(src_buffer, dest_buffer, data->width); } - fetchSrc = 0; - fetchMask = 0; + fetchSrc = NULL; + fetchMask = NULL; } for (i = 0; i < data->height; ++i) { Index: pixman/src/fbpict.c =================================================================== RCS file: /cvs/cairo/cairo/pixman/src/fbpict.c,v retrieving revision 1.4 diff -u -p -r1.4 fbpict.c --- pixman/src/fbpict.c 22 Aug 2005 03:49:47 -0000 1.4 +++ pixman/src/fbpict.c 23 Aug 2005 12:02:47 -0000 @@ -1360,7 +1360,7 @@ pixman_composite (pixman_operator_t op, pixman_region16_t *region; int n; pixman_box16_t *pbox; - CompositeFunc func = 0; + CompositeFunc func = NULL; Bool srcRepeat = pSrc->pDrawable && pSrc->repeat == RepeatNormal; Bool maskRepeat = FALSE; Bool srcTransform = pSrc->transform != 0; Index: pixman/src/icbltone.c =================================================================== RCS file: /cvs/cairo/cairo/pixman/src/icbltone.c,v retrieving revision 1.12 diff -u -p -r1.12 icbltone.c --- pixman/src/icbltone.c 25 Jun 2005 22:03:17 -0000 1.12 +++ pixman/src/icbltone.c 23 Aug 2005 12:02:47 -0000 @@ -130,7 +130,7 @@ fbLaneTable(int bpp) case 32: return fb32Lane; } - return 0; + return NULL; } #endif @@ -233,11 +233,11 @@ fbBltOne (FbStip *src, /* * Get pointer to stipple mask array for this depth */ - fbBits = 0; /* unused */ + fbBits = NULL; /* unused */ if (pixelsPerDst <= 8) fbBits = fbStippleTable(pixelsPerDst); #ifndef FBNOPIXADDR - fbLane = 0; + fbLane = NULL; if (transparent && fgand == 0 && dstBpp >= 8) fbLane = fbLaneTable(dstBpp); #endif Index: pixman/src/icimage.c =================================================================== RCS file: /cvs/cairo/cairo/pixman/src/icimage.c,v retrieving revision 1.31 diff -u -p -r1.31 icimage.c --- pixman/src/icimage.c 14 Jul 2005 18:41:01 -0000 1.31 +++ pixman/src/icimage.c 23 Aug 2005 12:02:48 -0000 @@ -120,13 +120,13 @@ pixman_image_init (pixman_image_t *image image->componentAlpha = 0; image->compositeClipSource = 0; - image->alphaMap = 0; + image->alphaMap = NULL; image->alphaOrigin.x = 0; image->alphaOrigin.y = 0; image->clipOrigin.x = 0; image->clipOrigin.y = 0; - image->clientClip = 0; + image->clientClip = NULL; image->dither = 0L; @@ -148,7 +148,7 @@ pixman_image_init (pixman_image_t *image image->transform = NULL; image->filter = PIXMAN_FILTER_NEAREST; - image->filter_params = 0; + image->filter_params = NULL; image->filter_nparams = 0; @@ -175,7 +175,7 @@ pixman_image_set_transform (pixman_image } }; if (transform && memcmp (transform, &identity, sizeof (pixman_transform_t)) == 0) - transform = 0; + transform = NULL; if (transform) { @@ -192,7 +192,7 @@ pixman_image_set_transform (pixman_image if (image->transform) { free (image->transform); - image->transform = 0; + image->transform = NULL; } } return 0; Index: pixman/src/icrect.c =================================================================== RCS file: /cvs/cairo/cairo/pixman/src/icrect.c,v retrieving revision 1.18 diff -u -p -r1.18 icrect.c --- pixman/src/icrect.c 21 Aug 2005 04:28:57 -0000 1.18 +++ pixman/src/icrect.c 23 Aug 2005 12:02:48 -0000 @@ -350,7 +350,7 @@ pixman_fill_rectangles (pixman_operator_ while (nRects--) { - pixman_composite (op, src, 0, dst, 0, 0, 0, 0, + pixman_composite (op, src, NULL, dst, 0, 0, 0, 0, rects->x, rects->y, rects->width, Index: pixman/src/ictrap.c =================================================================== RCS file: /cvs/cairo/cairo/pixman/src/ictrap.c,v retrieving revision 1.26 diff -u -p -r1.26 ictrap.c --- pixman/src/ictrap.c 25 Jun 2005 03:13:19 -0000 1.26 +++ pixman/src/ictrap.c 23 Aug 2005 12:02:48 -0000 @@ -34,7 +34,7 @@ FbCreateAlphaPicture (pixman_image_t *ds int own_format = 0; if (width > 32767 || height > 32767) - return 0; + return NULL; if (!format) { @@ -44,7 +44,7 @@ FbCreateAlphaPicture (pixman_image_t *ds else format = pixman_format_create (PIXMAN_FORMAT_NAME_A8); if (!format) - return 0; + return NULL; } image = pixman_image_create (format, width, height); Index: src/cairo-matrix.c =================================================================== RCS file: /cvs/cairo/cairo/src/cairo-matrix.c,v retrieving revision 1.32 diff -u -p -r1.32 cairo-matrix.c --- src/cairo-matrix.c 22 Aug 2005 23:52:40 -0000 1.32 +++ src/cairo-matrix.c 23 Aug 2005 12:02:48 -0000 @@ -680,19 +680,19 @@ _cairo_matrix_is_integer_translation(con double _cairo_matrix_transformed_circle_major_axis (cairo_matrix_t *matrix, double radius) { - double a, b, c, d; + double a, b, c, d, f, g, h, i, j; _cairo_matrix_get_affine (matrix, &a, &b, &c, &d, NULL, NULL); - double i = a*a + b*b; - double j = c*c + d*d; + i = a*a + b*b; + j = c*c + d*d; - double f = 0.5 * (i + j); - double g = 0.5 * (i - j); - double h = a*c + b*d; + f = 0.5 * (i + j); + g = 0.5 * (i - j); + h = a*c + b*d; return radius * sqrt (f + sqrt (g*g+h*h)); Index: test/cairo-test.c =================================================================== RCS file: /cvs/cairo/cairo/test/cairo-test.c,v retrieving revision 1.54 diff -u -p -r1.54 cairo-test.c --- test/cairo-test.c 20 Aug 2005 14:56:05 -0000 1.54 +++ test/cairo-test.c 23 Aug 2005 12:02:48 -0000 @@ -56,7 +56,7 @@ /* Static data is messy, but we're coding for tests here, not a * general-purpose library, and it keeps the tests cleaner to avoid a * context object there, (though not a whole lot). */ -FILE *cairo_test_log_file; +static FILE *cairo_test_log_file; void cairo_test_log (const char *fmt, ...) @@ -376,9 +376,9 @@ create_xlib_surface (int width, int heig if (height == 0) height = 1; - xtc->dpy = dpy = XOpenDisplay (0); + xtc->dpy = dpy = XOpenDisplay (NULL); if (xtc->dpy == NULL) { - cairo_test_log ("Failed to open display: %s\n", XDisplayName(0)); + cairo_test_log ("Failed to open display: %s\n", XDisplayName(NULL)); return NULL; }