cvs: gd(GD_2_0) /libgd/tests/gd2 gd2_empty_file.c gd2_read.c /libgd/tests/gdimagecopyrotated bug00020.c /libgd/tests/gdimagefill bug00002_1.c
bug00002_2.c bug00002_3.c bug00002_4.c /libgd/tests/gdimagefilledellipse bug00010.c /libgd/tests/gdimageline bug00072.c gdimageline_aa.c
/libgd/tests/gdtest gdtest.c gdtest.h /libgd/tests/gif bug00005.c bug00060.c bug00066.c /libgd/tests/jpeg jpeg_empty_file.c jpeg_read.c
/libgd/tests/png bug00011.c bug00033.c

From: Date: Tue, 10 Apr 2007 20:32:37 +0000
Subject: cvs: gd(GD_2_0) /libgd/tests/gd2 gd2_empty_file.c gd2_read.c /libgd/tests/gdimagecopyrotated bug00020.c /libgd/tests/gdimagefill bug00002_1.c
bug00002_2.c bug00002_3.c bug00002_4.c /libgd/tests/gdimagefilledellipse bug00010.c /libgd/tests/gdimageline bug00072.c gdimageline_aa.c
/libgd/tests/gdtest gdtest.c gdtest.h /libgd/tests/gif bug00005.c bug00060.c bug00066.c /libgd/tests/jpeg jpeg_empty_file.c jpeg_read.c
/libgd/tests/png bug00011.c bug00033.c
Groups: php.gd.cvs 
Request: Send a blank email to php-gd-cvs+get-174@lists.php.net to get a copy of this message
pajoye Tue Apr 10 20:32:37 2007 UTC Modified files: (Branch: GD_2_0) /gd/libgd/tests/gd2 gd2_empty_file.c gd2_read.c /gd/libgd/tests/gdimagecopyrotated bug00020.c /gd/libgd/tests/gdimagefill bug00002_1.c bug00002_2.c bug00002_3.c bug00002_4.c /gd/libgd/tests/gdimagefilledellipse bug00010.c /gd/libgd/tests/gdimageline bug00072.c gdimageline_aa.c /gd/libgd/tests/gdtest gdtest.c gdtest.h /gd/libgd/tests/gif bug00005.c bug00060.c bug00066.c /gd/libgd/tests/jpeg jpeg_empty_file.c jpeg_read.c /gd/libgd/tests/png bug00011.c bug00033.c Log: - use a constant to get the top src dir - don't use const when it is not a const...

http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gd2/gd2_empty_file.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gd2/gd2_empty_file.c diff -u gd/libgd/tests/gd2/gd2_empty_file.c:1.1.2.1 gd/libgd/tests/gd2/gd2_empty_file.c:1.1.2.2 --- gd/libgd/tests/gd2/gd2_empty_file.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gd2/gd2_empty_file.c Tue Apr 10 20:32:35 2007 @@ -1,4 +1,4 @@ -/* $Id: gd2_empty_file.c,v 1.1.2.1 2007/04/01 19:48:43 pajoye Exp $ */ +/* $Id: gd2_empty_file.c,v 1.1.2.2 2007/04/10 20:32:35 pajoye Exp $ */ #include "gd.h" #include <stdio.h> #include <stdlib.h> @@ -10,7 +10,7 @@ FILE *fp; char path[1024]; - sprintf(path, "%s/gd2/empty.gd2", gdTestGetTopDir()); + sprintf(path, "%s/gd2/empty.gd2", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gd2/gd2_read.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gd2/gd2_read.c diff -u gd/libgd/tests/gd2/gd2_read.c:1.1.2.1 gd/libgd/tests/gd2/gd2_read.c:1.1.2.2 --- gd/libgd/tests/gd2/gd2_read.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gd2/gd2_read.c Tue Apr 10 20:32:35 2007 @@ -1,4 +1,4 @@ -/* $Id: gd2_read.c,v 1.1.2.1 2007/04/01 19:48:43 pajoye Exp $ */ +/* $Id: gd2_read.c,v 1.1.2.2 2007/04/10 20:32:35 pajoye Exp $ */ #include "gd.h" #include <stdio.h> #include <stdlib.h> @@ -11,7 +11,7 @@ FILE *fp; char path[1024]; - sprintf(path, "%s/gd2/conv_test.gd2", gdTestGetTopDir()); + sprintf(path, "%s/gd2/conv_test.gd2", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { @@ -22,7 +22,7 @@ im = gdImageCreateFromGd2(fp); fclose(fp); - sprintf(path, "%s/gd2/conv_test_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gd2/conv_test_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; gdImageDestroy(im); http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagecopyrotated/bug00020.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimagecopyrotated/bug00020.c diff -u gd/libgd/tests/gdimagecopyrotated/bug00020.c:1.1.2.1 gd/libgd/tests/gdimagecopyrotated/bug00020.c:1.1.2.2 --- gd/libgd/tests/gdimagecopyrotated/bug00020.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gdimagecopyrotated/bug00020.c Tue Apr 10 20:32:36 2007 @@ -1,4 +1,4 @@ -/* $Id: bug00020.c,v 1.1.2.1 2007/04/01 19:48:43 pajoye Exp $ */ +/* $Id: bug00020.c,v 1.1.2.2 2007/04/10 20:32:36 pajoye Exp $ */ #include "gd.h" #include "gdtest.h" @@ -10,7 +10,7 @@ int error = 0; char path[1024]; - sprintf(path, "%s/gdimagecopyrotated/bug00020_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimagecopyrotated/bug00020_exp.png", GDTEST_TOP_DIR); im = gdImageCreateTrueColor(width, width); gdImageFilledRectangle(im, 0,0, width, width, 0xFF0000); http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagefill/bug00002_1.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimagefill/bug00002_1.c diff -u gd/libgd/tests/gdimagefill/bug00002_1.c:1.1.2.1 gd/libgd/tests/gdimagefill/bug00002_1.c:1.1.2.2 --- gd/libgd/tests/gdimagefill/bug00002_1.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gdimagefill/bug00002_1.c Tue Apr 10 20:32:36 2007 @@ -23,8 +23,7 @@ gdImagePng(im,fp); fclose(fp); - - sprintf(path, "%s/gdimagefill/bug00002_1_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimagefill/bug00002_1_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagefill/bug00002_2.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimagefill/bug00002_2.c diff -u gd/libgd/tests/gdimagefill/bug00002_2.c:1.1.2.1 gd/libgd/tests/gdimagefill/bug00002_2.c:1.1.2.2 --- gd/libgd/tests/gdimagefill/bug00002_2.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gdimagefill/bug00002_2.c Tue Apr 10 20:32:36 2007 @@ -8,7 +8,7 @@ int im_white, im_black, tile_white, tile_black; int x,y, error = 0; FILE *fp; - const char path[1024]; + char path[1024]; fputs("flag 0\n", stdout); im = gdImageCreate(150, 150); @@ -39,7 +39,7 @@ fputs("flag 2\n", stdout); - sprintf(path, "%s/gdimagefill/bug00002_2_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimagefill/bug00002_2_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagefill/bug00002_3.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimagefill/bug00002_3.c diff -u gd/libgd/tests/gdimagefill/bug00002_3.c:1.1.2.1 gd/libgd/tests/gdimagefill/bug00002_3.c:1.1.2.2 --- gd/libgd/tests/gdimagefill/bug00002_3.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gdimagefill/bug00002_3.c Tue Apr 10 20:32:36 2007 @@ -1,4 +1,4 @@ -/* $Id: bug00002_3.c,v 1.1.2.1 2007/04/01 19:48:43 pajoye Exp $ */ +/* $Id: bug00002_3.c,v 1.1.2.2 2007/04/10 20:32:36 pajoye Exp $ */ #include <gd.h> #include <stdio.h> #include "gdtest.h" @@ -9,7 +9,7 @@ int im_white, im_black, tile_white, tile_black; int x,y, error = 0; FILE *fp; - const char path[1024]; + char path[1024]; fputs("flag 0\n", stdout); im = gdImageCreate(150, 150); @@ -45,7 +45,7 @@ gdImageFill(im, 0, 0, 0xffffff); fputs("flag 3\n", stdout); - sprintf(path, "%s/gdimagefill/bug00002_3_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimagefill/bug00002_3_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagefill/bug00002_4.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimagefill/bug00002_4.c diff -u gd/libgd/tests/gdimagefill/bug00002_4.c:1.1.2.1 gd/libgd/tests/gdimagefill/bug00002_4.c:1.1.2.2 --- gd/libgd/tests/gdimagefill/bug00002_4.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gdimagefill/bug00002_4.c Tue Apr 10 20:32:36 2007 @@ -8,7 +8,7 @@ gdImagePtr im; FILE *fp; int red, blue, white, black, error = 0; - const char path[1024]; + char path[1024]; im = gdImageCreate(50,100); red = gdImageColorAllocate(im, 255, 0, 0); @@ -30,7 +30,7 @@ gdImageFill(im, 100,69, red); gdImageFill(im, 100,21, white); - sprintf(path, "%s/gdimagefill/bug00002_4_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimagefill/bug00002_4_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimagefilledellipse/bug00010.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimagefilledellipse/bug00010.c diff -u gd/libgd/tests/gdimagefilledellipse/bug00010.c:1.1.2.1 gd/libgd/tests/gdimagefilledellipse/bug00010.c:1.1.2.2 --- gd/libgd/tests/gdimagefilledellipse/bug00010.c:1.1.2.1 Sun Apr 1 19:48:43 2007 +++ gd/libgd/tests/gdimagefilledellipse/bug00010.c Tue Apr 10 20:32:36 2007 @@ -1,4 +1,4 @@ -/* $Id: bug00010.c,v 1.1.2.1 2007/04/01 19:48:43 pajoye Exp $ */ +/* $Id: bug00010.c,v 1.1.2.2 2007/04/10 20:32:36 pajoye Exp $ */ #include "gd.h" #include "gdtest.h" @@ -11,7 +11,7 @@ im = gdImageCreateTrueColor(100,100); gdImageFilledEllipse(im, 50,50, 70, 90, 0x50FFFFFF); - sprintf(path, "%s/gdimagefilledellipse/bug00010_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimagefilledellipse/bug00010_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimageline/bug00072.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gdimageline/bug00072.c diff -u gd/libgd/tests/gdimageline/bug00072.c:1.1.2.1 gd/libgd/tests/gdimageline/bug00072.c:1.1.2.2 --- gd/libgd/tests/gdimageline/bug00072.c:1.1.2.1 Mon Apr 9 16:18:43 2007 +++ gd/libgd/tests/gdimageline/bug00072.c Tue Apr 10 20:32:36 2007 @@ -27,8 +27,7 @@ gdImageLine(im, 0, 5, 11, 5, 0xFF0000); gdImageLine(im, 0, 0, 11, 11, 0xFF0000); - - sprintf(path, "%s/gdimageline/%s", gdTestGetTopDir(), exp); + sprintf(path, "%s/gdimageline/%s", GDTEST_TOP_DIR, exp); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdimageline/gdimageline_aa.c?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: gd/libgd/tests/gdimageline/gdimageline_aa.c diff -u gd/libgd/tests/gdimageline/gdimageline_aa.c:1.1.2.2 gd/libgd/tests/gdimageline/gdimageline_aa.c:1.1.2.3 --- gd/libgd/tests/gdimageline/gdimageline_aa.c:1.1.2.2 Mon Apr 9 14:00:39 2007 +++ gd/libgd/tests/gdimageline/gdimageline_aa.c Tue Apr 10 20:32:36 2007 @@ -47,27 +47,29 @@ { int i; int error = 0; - const char path[1024]; + char path[1024]; + const char *srcdir; + int n; - sprintf(path, "%s/gdimageline/gdimageline_aa_a_0_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_a_0_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,0,1,10,100, 1); - sprintf(path, "%s/gdimageline/gdimageline_aa_a_1_exp.png", gdTestGetTopDir()); + + sprintf(path, "%s/gdimageline/gdimageline_aa_a_1_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,1,1,10,100, 2); - sprintf(path, "%s/gdimageline/gdimageline_aa_b_0_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_b_0_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,2,-1,10,100, 1); - sprintf(path, "%s/gdimageline/gdimageline_aa_b_1_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_b_1_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,1,-1,10,100, 2); - - sprintf(path, "%s/gdimageline/gdimageline_aa_c_0_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_c_0_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,0,1,100,10, 1); - sprintf(path, "%s/gdimageline/gdimageline_aa_c_1_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_c_1_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,1,1,100,10, 2); - sprintf(path, "%s/gdimageline/gdimageline_aa_d_0_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_d_0_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,2,-1,100,10, 1); - sprintf(path, "%s/gdimageline/gdimageline_aa_d_1_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gdimageline/gdimageline_aa_d_1_exp.png", GDTEST_TOP_DIR); error |= gen_image(path,1,-1,100,10, 2); return error; http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdtest/gdtest.c?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: gd/libgd/tests/gdtest/gdtest.c diff -u gd/libgd/tests/gdtest/gdtest.c:1.1.2.2 gd/libgd/tests/gdtest/gdtest.c:1.1.2.3 --- gd/libgd/tests/gdtest/gdtest.c:1.1.2.2 Mon Apr 9 14:00:39 2007 +++ gd/libgd/tests/gdtest/gdtest.c Tue Apr 10 20:32:36 2007 @@ -9,10 +9,6 @@ #include "gdtest.h" #include "test_config.h" -const char * gdTestGetTopDir() -{ - return GDTEST_TOP_DIR; -} gdImagePtr gdTestImageFromPng(const char *filename) { http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gdtest/gdtest.h?r1=1.1&r2=1.1.2.1&diff_format=u Index: gd/libgd/tests/gdtest/gdtest.h diff -u gd/libgd/tests/gdtest/gdtest.h:1.1 gd/libgd/tests/gdtest/gdtest.h:1.1.2.1 --- gd/libgd/tests/gdtest/gdtest.h:1.1 Tue Jan 23 23:57:54 2007 +++ gd/libgd/tests/gdtest/gdtest.h Tue Apr 10 20:32:36 2007 @@ -3,6 +3,8 @@ #include <stdarg.h> #include <gd.h> +#include "test_config.h" + #define GDTEST_STRING_MAX 1024 typedef struct CuTestImageResult CuTestImageResult; struct CuTestImageResult { http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gif/bug00005.c?r1=1.2.2.2&r2=1.2.2.3&diff_format=u Index: gd/libgd/tests/gif/bug00005.c diff -u gd/libgd/tests/gif/bug00005.c:1.2.2.2 gd/libgd/tests/gif/bug00005.c:1.2.2.3 --- gd/libgd/tests/gif/bug00005.c:1.2.2.2 Mon Apr 9 14:00:39 2007 +++ gd/libgd/tests/gif/bug00005.c Tue Apr 10 20:32:37 2007 @@ -15,7 +15,7 @@ char path[1024]; for (i=0; i < files_cnt; i++) { - sprintf(path, "%s/gif/%s", gdTestGetTopDir(), giffiles[i]); + sprintf(path, "%s/gif/%s", GDTEST_TOP_DIR, giffiles[i]); fp = fopen(path, "rb"); if (!fp) { @@ -30,7 +30,7 @@ if (!im) { error = 1; } else { - sprintf(path, "%s/gif/%s", gdTestGetTopDir(), exp[i]); + sprintf(path, "%s/gif/%s", GDTEST_TOP_DIR, exp[i]); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gif/bug00060.c?r1=1.1.2.2&r2=1.1.2.3&diff_format=u Index: gd/libgd/tests/gif/bug00060.c diff -u gd/libgd/tests/gif/bug00060.c:1.1.2.2 gd/libgd/tests/gif/bug00060.c:1.1.2.3 --- gd/libgd/tests/gif/bug00060.c:1.1.2.2 Wed Apr 4 12:04:07 2007 +++ gd/libgd/tests/gif/bug00060.c Tue Apr 10 20:32:37 2007 @@ -1,15 +1,15 @@ #include <stdio.h> #include <gd.h> +#include <gdtest.h> int main() { gdImagePtr im; FILE *fp; - const char path[1024]; - - sprintf(path, "%s/gif/bug00060.gif", gdTestGetTopDir()); + char path[1024]; + sprintf(path, "%s/gif/bug00060.gif", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { http://cvs.php.net/viewvc.cgi/gd/libgd/tests/gif/bug00066.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/gif/bug00066.c diff -u gd/libgd/tests/gif/bug00066.c:1.1.2.1 gd/libgd/tests/gif/bug00066.c:1.1.2.2 --- gd/libgd/tests/gif/bug00066.c:1.1.2.1 Wed Apr 4 12:04:07 2007 +++ gd/libgd/tests/gif/bug00066.c Tue Apr 10 20:32:37 2007 @@ -6,11 +6,10 @@ { gdImagePtr im; FILE *fp; - const char path[1024]; + char path[1024]; int error = 0; - sprintf(path, "%s/gif/bug00066.gif", gdTestGetTopDir()); - + sprintf(path, "%s/gif/bug00066.gif", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { @@ -21,7 +20,7 @@ im = gdImageCreateFromGif(fp); fclose(fp); - sprintf(path, "%s/gif/bug00066_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/gif/bug00066_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } http://cvs.php.net/viewvc.cgi/gd/libgd/tests/jpeg/jpeg_empty_file.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/jpeg/jpeg_empty_file.c diff -u gd/libgd/tests/jpeg/jpeg_empty_file.c:1.1.2.1 gd/libgd/tests/jpeg/jpeg_empty_file.c:1.1.2.2 --- gd/libgd/tests/jpeg/jpeg_empty_file.c:1.1.2.1 Sun Apr 1 19:48:44 2007 +++ gd/libgd/tests/jpeg/jpeg_empty_file.c Tue Apr 10 20:32:37 2007 @@ -1,4 +1,4 @@ -/* $Id: jpeg_empty_file.c,v 1.1.2.1 2007/04/01 19:48:44 pajoye Exp $ */ +/* $Id: jpeg_empty_file.c,v 1.1.2.2 2007/04/10 20:32:37 pajoye Exp $ */ #include "gd.h" #include <stdio.h> #include <stdlib.h> @@ -10,7 +10,7 @@ FILE *fp; const char path[1024]; - sprintf(path, "%s/jpeg/empty.jpeg", gdTestGetTopDir()); + sprintf(path, "%s/jpeg/empty.jpeg", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { printf("failed, cannot open file\n"); http://cvs.php.net/viewvc.cgi/gd/libgd/tests/jpeg/jpeg_read.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/jpeg/jpeg_read.c diff -u gd/libgd/tests/jpeg/jpeg_read.c:1.1.2.1 gd/libgd/tests/jpeg/jpeg_read.c:1.1.2.2 --- gd/libgd/tests/jpeg/jpeg_read.c:1.1.2.1 Sun Apr 1 19:48:44 2007 +++ gd/libgd/tests/jpeg/jpeg_read.c Tue Apr 10 20:32:37 2007 @@ -1,4 +1,4 @@ -/* $Id: jpeg_read.c,v 1.1.2.1 2007/04/01 19:48:44 pajoye Exp $ */ +/* $Id: jpeg_read.c,v 1.1.2.2 2007/04/10 20:32:37 pajoye Exp $ */ #include "gd.h" #include <stdio.h> #include <stdlib.h> @@ -9,9 +9,9 @@ int error; gdImagePtr im; FILE *fp; - const char path[1024]; + char path[1024]; - sprintf(path, "%s/jpeg/conv_test.jpeg", gdTestGetTopDir()); + sprintf(path, "%s/jpeg/conv_test.jpeg", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { printf("failed, cannot open file\n"); @@ -21,7 +21,7 @@ im = gdImageCreateFromJpeg(fp); fclose(fp); - sprintf(path, "%s/jpeg/conv_test_exp.png", gdTestGetTopDir()); + sprintf(path, "%s/jpeg/conv_test_exp.png", GDTEST_TOP_DIR); if (!gdAssertImageEqualsToFile(path, im)) { error = 1; } else { http://cvs.php.net/viewvc.cgi/gd/libgd/tests/png/bug00011.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/png/bug00011.c diff -u gd/libgd/tests/png/bug00011.c:1.1.2.1 gd/libgd/tests/png/bug00011.c:1.1.2.2 --- gd/libgd/tests/png/bug00011.c:1.1.2.1 Sun Apr 1 19:48:44 2007 +++ gd/libgd/tests/png/bug00011.c Tue Apr 10 20:32:37 2007 @@ -1,4 +1,4 @@ -/* $Id: bug00011.c,v 1.1.2.1 2007/04/01 19:48:44 pajoye Exp $ */ +/* $Id: bug00011.c,v 1.1.2.2 2007/04/10 20:32:37 pajoye Exp $ */ #include "gd.h" #include <stdio.h> #include <stdlib.h> @@ -10,7 +10,7 @@ FILE *fp; char path[2048]; - sprintf(path, "%s/png/emptyfile", gdTestGetTopDir()); + sprintf(path, "%s/png/emptyfile", GDTEST_TOP_DIR); printf("opening %s\n", path); fp = fopen(path, "rb"); if (!fp) { http://cvs.php.net/viewvc.cgi/gd/libgd/tests/png/bug00033.c?r1=1.1.2.1&r2=1.1.2.2&diff_format=u Index: gd/libgd/tests/png/bug00033.c diff -u gd/libgd/tests/png/bug00033.c:1.1.2.1 gd/libgd/tests/png/bug00033.c:1.1.2.2 --- gd/libgd/tests/png/bug00033.c:1.1.2.1 Sun Apr 1 19:48:44 2007 +++ gd/libgd/tests/png/bug00033.c Tue Apr 10 20:32:37 2007 @@ -1,4 +1,4 @@ -/* $Id: bug00033.c,v 1.1.2.1 2007/04/01 19:48:44 pajoye Exp $ */ +/* $Id: bug00033.c,v 1.1.2.2 2007/04/10 20:32:37 pajoye Exp $ */ #include "gd.h" #include <stdio.h> #include <stdlib.h> @@ -8,9 +8,9 @@ { gdImagePtr im; FILE *fp; - const char path[1024]; + char path[1024]; - sprintf(path, "%s/png/bug00033.png", gdTestGetTopDir()); + sprintf(path, "%s/png/bug00033.png", GDTEST_TOP_DIR); fp = fopen(path, "rb"); if (!fp) { printf("failed, cannot open file <%s>\n", path);
« previous php.gd.cvs (#174) next »