diff options
author | joerg <joerg@pkgsrc.org> | 2012-11-01 19:53:04 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2012-11-01 19:53:04 +0000 |
commit | 44c7cc729eea77d2aea7461f1f22246925a516fa (patch) | |
tree | bcfd5a806f70dafc072c7c58bae4ea34aef61a1f | |
parent | dbf51483235df2b67826c438a4937589a458e7aa (diff) | |
download | pkgsrc-44c7cc729eea77d2aea7461f1f22246925a516fa.tar.gz |
Add missing return values.
-rw-r--r-- | graphics/xart/distinfo | 4 | ||||
-rw-r--r-- | graphics/xart/patches/patch-ab | 23 | ||||
-rw-r--r-- | lang/ucblogo/distinfo | 5 | ||||
-rw-r--r-- | lang/ucblogo/patches/patch-graphics.c | 103 | ||||
-rw-r--r-- | lang/ucblogo/patches/patch-xgraphics.c | 22 | ||||
-rw-r--r-- | lang/ucblogo/patches/patch-xgraphics.h | 21 |
6 files changed, 172 insertions, 6 deletions
diff --git a/graphics/xart/distinfo b/graphics/xart/distinfo index a20936b5e44..b2e9ae75ae4 100644 --- a/graphics/xart/distinfo +++ b/graphics/xart/distinfo @@ -1,10 +1,10 @@ -$NetBSD: distinfo,v 1.15 2011/12/05 22:48:58 joerg Exp $ +$NetBSD: distinfo,v 1.16 2012/11/01 19:53:04 joerg Exp $ SHA1 (xart19980415.tgz) = d4445392e33a5dcf5ae951babac82394e7cdd65c RMD160 (xart19980415.tgz) = 99077c23a798d8c0026bd53450052b1a8cf6ff6f Size (xart19980415.tgz) = 343909 bytes SHA1 (patch-aa) = 7d8ae61d9a624cc537396f406b496f28376cf7b5 -SHA1 (patch-ab) = b0f00e29560ce786e37a8ba62fef82dae80c4ee9 +SHA1 (patch-ab) = 326a02c9cb6698a0d4f4cbf372ce71ff2be00958 SHA1 (patch-ac) = 618003b6d192e85a1aa5f64b0f8eccfec991012e SHA1 (patch-ad) = 9bea96736f23880863f1aa2ccb5499d64f5e781c SHA1 (patch-ae) = d0d87fe957cbec5979e635270d2ad05b294f7530 diff --git a/graphics/xart/patches/patch-ab b/graphics/xart/patches/patch-ab index 9c3f77cec3e..30d426713a6 100644 --- a/graphics/xart/patches/patch-ab +++ b/graphics/xart/patches/patch-ab @@ -1,7 +1,7 @@ -$NetBSD: patch-ab,v 1.2 1998/08/07 10:40:54 agc Exp $ +$NetBSD: patch-ab,v 1.3 2012/11/01 19:53:04 joerg Exp $ ---- dynPenOp.c.orig Tue Apr 21 00:57:13 1998 -+++ dynPenOp.c Tue Apr 21 01:08:15 1998 +--- dynPenOp.c.orig 1998-04-12 15:07:04.000000000 +0000 ++++ dynPenOp.c @@ -24,11 +24,12 @@ #include <X11/Intrinsic.h> #include <X11/StringDefs.h> @@ -16,3 +16,20 @@ $NetBSD: patch-ab,v 1.2 1998/08/07 10:40:54 agc Exp $ typedef struct { float startx, starty; +@@ -185,7 +186,7 @@ timeout(XtPointer client_data, XtInterva + XPeekIfEvent(XtDisplay(l->w), &ev, dummy_pred, NULL); + + if (ev.type == MotionNotify) +- return; ++ return 0; + + /* It's a PropertyNotify */ + l->tid = 0; +@@ -194,6 +195,7 @@ timeout(XtPointer client_data, XtInterva + me.time = ev.xproperty.time; + + motion(l->w, l, &me, l->opinfo); ++ return 0; + } + + static void diff --git a/lang/ucblogo/distinfo b/lang/ucblogo/distinfo index 1a369944fb9..f50c739ce15 100644 --- a/lang/ucblogo/distinfo +++ b/lang/ucblogo/distinfo @@ -1,6 +1,9 @@ -$NetBSD: distinfo,v 1.6 2009/12/10 23:42:14 asau Exp $ +$NetBSD: distinfo,v 1.7 2012/11/01 19:55:37 joerg Exp $ SHA1 (ucblogo-5.3.tar.gz) = abe27b2a36cc5d8dc4208fba04569e82cc163719 RMD160 (ucblogo-5.3.tar.gz) = 9dfaf9886335ff7624e72cd23d0fd28a80e679c3 Size (ucblogo-5.3.tar.gz) = 1180188 bytes SHA1 (patch-aa) = 7e3ab4e800f726dea6e6a46eb22ee6b7b8b03509 +SHA1 (patch-graphics.c) = 5ebe5e76e07d5692105ca9f37c665924486f180a +SHA1 (patch-xgraphics.c) = d1f58d85260d650a37f0b3bf12097656f352078c +SHA1 (patch-xgraphics.h) = 3b4c6a74cd328241dd2ea8c601879bd24911570d diff --git a/lang/ucblogo/patches/patch-graphics.c b/lang/ucblogo/patches/patch-graphics.c new file mode 100644 index 00000000000..857c9dca673 --- /dev/null +++ b/lang/ucblogo/patches/patch-graphics.c @@ -0,0 +1,103 @@ +$NetBSD: patch-graphics.c,v 1.1 2012/11/01 19:55:37 joerg Exp $ + +--- graphics.c.orig 2012-10-30 22:02:54.000000000 +0000 ++++ graphics.c +@@ -535,7 +535,7 @@ NODE *lback(NODE *arg) { + } + + NODE *lshowturtle(NODE *args) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + if (!turtle_shown) { + turtle_shown = TRUE; + draw_turtle(); +@@ -545,7 +545,7 @@ NODE *lshowturtle(NODE *args) { + } + + NODE *lhideturtle(NODE *args) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + if (turtle_shown) { + draw_turtle(); + turtle_shown = FALSE; +@@ -874,7 +874,7 @@ NODE *llabel(NODE *arg) { + *print_stringptr = '\0'; + + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + draw_turtle(); + theLength = strlen(textbuf); + #ifdef mac +@@ -983,7 +983,7 @@ NODE *lsetpencolor(NODE *arg) { + NODE *val = pos_int_arg(arg); + + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + set_pen_color(getint(val)); + save_color(); + done_drawing; +@@ -995,7 +995,7 @@ NODE *lsetbackground(NODE *arg) { + NODE *val = pos_int_arg(arg); + + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + set_back_ground(getint(val)); + done_drawing; + } +@@ -1008,7 +1008,7 @@ NODE *lsetpalette(NODE *args) { + int slotnum = (int)getint(slot); + + if (NOT_THROWING && (slotnum > 7)) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + set_palette(slotnum, + (unsigned int)getint(car(arg)), + (unsigned int)getint(cadr(arg)), +@@ -1057,7 +1057,7 @@ NODE *lsetpensize(NODE *args) { + NODE *arg = pos_int_vector_arg(args); + + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + set_pen_width((int)getint(car(arg))); + set_pen_height((int)getint(cadr(arg))); + save_size(); +@@ -1074,7 +1074,7 @@ NODE *lsetpenpattern(NODE *args) { + arg = err_logo(BAD_DATA, arg); + + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + set_list_pen_pattern(arg); + save_pattern(); + done_drawing; +@@ -1090,7 +1090,7 @@ NODE *lsetscrunch(NODE *args) { + ynode = numeric_arg(cdr(args)); + + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + draw_turtle(); + x_scale = (nodetype(xnode) == FLOATT) ? getfloat(xnode) : + (FLONUM)getint(xnode); +@@ -1227,7 +1227,7 @@ NODE *larc(NODE *arg) { + else + radius = getfloat(val2); + +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + draw_turtle(); + + /* save and force turtle state */ +@@ -1582,7 +1582,7 @@ NODE *lloadpict(NODE *args) { + lopenread(args); + #endif + if (NOT_THROWING) { +- prepare_to_draw; ++ prepare_to_draw2(UNBOUND); + fp = (FILE *)file_list->n_obj; + restore_palette(fp); + fread(&record_index, sizeof(FIXNUM), 1, fp); diff --git a/lang/ucblogo/patches/patch-xgraphics.c b/lang/ucblogo/patches/patch-xgraphics.c new file mode 100644 index 00000000000..2a4da3f76aa --- /dev/null +++ b/lang/ucblogo/patches/patch-xgraphics.c @@ -0,0 +1,22 @@ +$NetBSD: patch-xgraphics.c,v 1.1 2012/11/01 19:55:37 joerg Exp $ + +--- xgraphics.c.orig 2012-10-30 22:05:56.000000000 +0000 ++++ xgraphics.c +@@ -289,7 +289,7 @@ void placate_x() + + int get_mouse_x() + { +- checkX; ++ checkX2(-1); + + placate_x(); + +@@ -299,7 +299,7 @@ int get_mouse_x() + + int get_mouse_y() + { +- checkX; ++ checkX2(-1); + + placate_x(); + diff --git a/lang/ucblogo/patches/patch-xgraphics.h b/lang/ucblogo/patches/patch-xgraphics.h new file mode 100644 index 00000000000..086be62253c --- /dev/null +++ b/lang/ucblogo/patches/patch-xgraphics.h @@ -0,0 +1,21 @@ +$NetBSD: patch-xgraphics.h,v 1.1 2012/11/01 19:55:37 joerg Exp $ + +--- xgraphics.h.orig 2012-10-30 22:03:25.000000000 +0000 ++++ xgraphics.h +@@ -30,6 +30,16 @@ void logofill(void); + } + + #define prepare_to_draw {checkX; placate_x();} ++ ++#define checkX2(err) { \ ++ if (have_x < 0) real_window_init(); \ ++ if (!have_x) { \ ++ err_logo(BAD_GRAPH_INIT,NIL); \ ++ return (err); \ ++ } \ ++} ++ ++#define prepare_to_draw2(err) {checkX2(err); placate_x();} + #define done_drawing XFlush(dpy) + extern void placate_x(); + |