diff -up magicpoint-1.11b/image/path.c~ magicpoint-1.11b/image/path.c --- magicpoint-1.11b/image/path.c~ 2008-03-30 22:02:58.000000000 +0200 +++ magicpoint-1.11b/image/path.c 2008-03-30 22:02:58.000000000 +0200 @@ -20,9 +20,7 @@ #if 1 /* SYSV */ #include #endif -#ifdef __APPLE__ #include -#endif /* SUPPRESS 530 */ /* SUPPRESS 560 */ diff -up magicpoint-1.11b/image/window.c~ magicpoint-1.11b/image/window.c --- magicpoint-1.11b/image/window.c~ 2008-03-30 22:04:06.000000000 +0200 +++ magicpoint-1.11b/image/window.c 2008-03-30 22:05:22.000000000 +0200 @@ -16,7 +16,7 @@ #include #include #include -#ifdef SYSV +#if 1 /* SYSV */ #include #endif #if TIME_WITH_SYS_TIME diff -up magicpoint-1.11b/image/misc.c~ magicpoint-1.11b/image/misc.c --- magicpoint-1.11b/image/misc.c~ 2008-03-30 22:01:28.000000000 +0200 +++ magicpoint-1.11b/image/misc.c 2008-03-30 22:01:28.000000000 +0200 @@ -12,9 +12,7 @@ #include "xloadimage.h" #include "patchlevel" #include -#ifdef __APPLE__ #include -#endif extern int _Xdebug; extern Display *display; diff -up magicpoint-1.11b/draw.c~ magicpoint-1.11b/draw.c --- magicpoint-1.11b/draw.c~ 2008-03-30 21:50:02.000000000 +0200 +++ magicpoint-1.11b/draw.c 2008-03-30 21:50:02.000000000 +0200 @@ -2660,7 +2660,7 @@ x_setfont(xfont, csize, registry, truesc fprintf(stderr, "using best [%d] <%s>\n", best, fontlist[best]); } - strlcpy(fontstring, fontlist[best], sizeof(fontstring)); + snprintf(fontstring, sizeof(fontstring), "%s", fontlist[best]); } else if (scalable >= 0 || tscalable >= 0) { x_fontname(fontstring, sizeof(fontstring), xfont, csize, registry); @@ -4911,23 +4911,23 @@ xft_setfont(xfontarg, csize, registry) */ if ((p = strchr(xfont, '-')) != NULL) { *p++ = 0; - strlcpy(font, xfont, sizeof(font)); + snprintf(font, sizeof(font), "%s", xfont); if (strncmp(p, "bold-i", 6) == 0) - strlcpy(style, "Bold Italic", sizeof(style)); + snprintf(style, sizeof(style), "%s", "Bold Italic"); else if (strncmp(p, "bold-", 5) == 0) - strlcpy(style, "Bold", sizeof(style)); + snprintf(style, sizeof(style), "%s", "Bold"); else if ((p = strchr(p, '-')) != NULL && p[1] == 'i') - strlcpy(style, "Italic", sizeof(style)); + snprintf(style, sizeof(style), "%s", "Italic"); } else if ((p = strchr(xfont, ':')) == NULL) - strlcpy(font, xfont, sizeof(font)); + snprintf(font, sizeof(font), "%s", xfont); else { p2 = p +1; /* allow to use ":style=" syntax */ if ((strstr(p2, "style=") != NULL) || (strstr(p2, "STYLE=") != NULL)) p2 += 6; *p = '\0'; - strlcpy(font, xfont, sizeof(font)); - strlcpy(style, p2, sizeof(style)); + snprintf(font, sizeof(font), "%s", xfont); + snprintf(style, sizeof(style), "%s", p2); } if (style[0]) { xftfont = XftFontOpen(display, screen, diff -up magicpoint-1.11b/contrib/xwintoppm/dsimple.c~ magicpoint-1.11b/contrib/xwintoppm/dsimple.c --- magicpoint-1.11b/contrib/xwintoppm/dsimple.c~ 2008-03-30 22:13:20.000000000 +0200 +++ magicpoint-1.11b/contrib/xwintoppm/dsimple.c 2008-03-30 22:13:20.000000000 +0200 @@ -57,6 +57,7 @@ void blip(); Window Window_With_Name(); void Fatal_Error(); void outl(char *msg, ...); +int usage(void); /* * Just_display: A group of routines designed to make the writting of simple diff -up magicpoint-1.11b/contrib/xwintoppm/xwintoppm.c~ magicpoint-1.11b/contrib/xwintoppm/xwintoppm.c --- magicpoint-1.11b/contrib/xwintoppm/xwintoppm.c~ 2008-03-30 22:11:46.000000000 +0200 +++ magicpoint-1.11b/contrib/xwintoppm/xwintoppm.c 2008-03-30 22:13:40.000000000 +0200 @@ -96,6 +96,7 @@ in this Software without prior written a %*/ #include +#include #include #include @@ -125,6 +126,12 @@ typedef unsigned long Pixel; #include #endif +int usage(void); +int Error(char *); +void outl(char *msg, ...); +int Image_Size(XImage *image); +int Get_XColors(XWindowAttributes *win_info, XColor **colors); + /* Setable Options */ int format = ZPixmap; diff -up magicpoint-1.11b/mgp.h~ magicpoint-1.11b/mgp.h --- magicpoint-1.11b/mgp.h~ 2008-03-30 21:59:13.000000000 +0200 +++ magicpoint-1.11b/mgp.h 2008-03-30 21:59:13.000000000 +0200 @@ -799,6 +799,7 @@ extern XImage *tfc_image __P((struct tfo /* unimap.c */ extern void latin_unicode_map_init(); +extern void unicode_map_init(); /* embed.c */ extern char *embed_fname __P((char *)); diff -up magicpoint-1.11b/mgp.c~ magicpoint-1.11b/mgp.c --- magicpoint-1.11b/mgp.c~ 2008-03-30 21:45:20.000000000 +0200 +++ magicpoint-1.11b/mgp.c 2008-03-30 21:45:20.000000000 +0200 @@ -441,7 +441,7 @@ main(argc, argv) } init_win1(xgeometry); - strlcpy(buf, mgp_fname, sizeof(buf)); + snprintf(buf, sizeof(buf), "%s", mgp_fname); if ((p = rindex(buf, '/'))) { *p = '\0'; Paths[NumPaths++]= expandPath(buf); diff -up magicpoint-1.11b/grammar.y~ magicpoint-1.11b/grammar.y --- magicpoint-1.11b/grammar.y~ 2008-03-30 22:17:54.000000000 +0200 +++ magicpoint-1.11b/grammar.y 2008-03-30 22:17:54.000000000 +0200 @@ -74,6 +74,7 @@ int n_errors = 0; struct ctrl *root; char *yyfilename; int yylineno; +extern int yylex (void); #ifdef HAVE_STDARG_H /* GCC complains if we declare this function in traditional style */