diff options
Diffstat (limited to 'graphics/tgd/files/patch-ab')
-rw-r--r-- | graphics/tgd/files/patch-ab | 157 |
1 files changed, 157 insertions, 0 deletions
diff --git a/graphics/tgd/files/patch-ab b/graphics/tgd/files/patch-ab new file mode 100644 index 000000000000..70597d57755e --- /dev/null +++ b/graphics/tgd/files/patch-ab @@ -0,0 +1,157 @@ +--- tgd.c.orig Mon Oct 7 15:31:25 1996 ++++ tgd.c Sat Apr 3 11:41:37 1999 +@@ -31,7 +31,7 @@ + #include <strings.h> + #endif + #include <ctype.h> +-#include <malloc.h> ++#include <stdlib.h> + #include "gd.h" + #include "gdfontl.h" + #include "gdfonts.h" +@@ -40,6 +40,7 @@ + #include "gdfontt.h" + #include "tgdsamfont.h" + #include "tgd.h" ++#include "tgdcommand.h" + + static char SCCS[] = "@(#)tgd.c 1.6 10/13/95 tgd"; + static char *Current_file; /* Name of current input file */ +@@ -54,9 +55,11 @@ + COLOUR *colourbyname(); + TIM *timbyname(); + static void tgdgo(); +-static init(); ++static void init(); ++static void loadfonts(); ++static void unloadfonts(); + +-main( argc, argv ) ++int main( argc, argv ) + int argc; + char *argv[]; + { +@@ -79,7 +82,7 @@ + fclose( fp ); + } + } +- exit( 0 ); ++ return 0; + } + + +@@ -87,7 +90,7 @@ + * Unrecoverable error, terminate program with + * a message. + */ +-die( s ) ++void die( char *s ) + { + char buf[BUFSIZ]; + sprintf( buf, "tgd error is [%s]. Near line %d in file %s.\n", +@@ -101,7 +104,7 @@ + * Setting Ldebug less than 0 will completely + * shut program up. + */ +-tgdputs( s ) ++void tgdputs( s ) + char *s; + { + if ( Ldebug >= 0 ) +@@ -111,7 +114,7 @@ + /* -- + * All error reports should go through here. + */ +-tgdputerr( s ) ++void tgdputerr( char *s ) + { + fprintf( Fp_err, "%s\n", s ); + } +@@ -120,7 +123,7 @@ + * (Re)Initialize datastructures for each input file. + */ + static +-init() ++void init() + { + int i, j; + +@@ -236,13 +239,14 @@ + } + } + die( "too many images" ); ++ return 0; /* turn off compiler warning */ + } + + /* -- + * Called when we read in an image to synchronize + * our conception of the image with the GD library. + */ +-timset( tim ) ++void timset( tim ) + TIM *tim; + { + int colors; +@@ -306,7 +310,7 @@ + * off all standard output, including that from + * printing functions. + */ +-tgddebug( argc, argv ) ++void tgddebug( argc, argv ) + int argc; + char *argv[]; + { +@@ -316,7 +320,7 @@ + /* -- + * center the string on the given x y coords. (see imagestring) + */ +-tgdstringcenter( argc, argv ) ++void tgdstringcenter( argc, argv ) + int argc; + char *argv[]; + { +@@ -347,7 +351,7 @@ + * Note that "macros" can be built + * up out of text commands. + */ +-tgdstockimage( argc, argv ) ++void tgdstockimage( argc, argv ) + int argc; + char *argv[]; + { +@@ -418,7 +422,7 @@ + /* -- + * Release argv strings + */ +-tgdargdestroy( argc, argv ) ++void tgdargdestroy( argc, argv ) + int argc; + char *argv[]; + { +@@ -434,7 +438,7 @@ + /* -- + * Report on the current comand. + */ +-tgdshowvector( argc, argv ) ++void tgdshowvector( argc, argv ) + int argc; + char *argv[]; + { +@@ -510,7 +514,7 @@ + * Font names are case-insenstive to user, so make names + * all lower case here (cf. fontbyname() ). + */ +-loadfonts() ++static void loadfonts() + { + /* Font kludge XXX */ + strcpy( Font[0].name, "gdfontsmall" ); +@@ -562,7 +566,7 @@ + /* -- + * Eventually will dump fonts out of memory + */ +-unloadfonts() ++static void unloadfonts() + { + /* XXX */ + } |