fix bug that can cause x to crash, bump pkgname to wmwave-0.4p1

from Chris Kuethe <ckuethe at ualberta.ca>

remove me as maintainer
This commit is contained in:
jcs 2004-04-23 20:29:20 +00:00
parent 4824dcfcfd
commit ab48dc8a93
2 changed files with 20 additions and 24 deletions

View File

@ -1,6 +1,6 @@
# $OpenBSD: Makefile,v 1.6 2002/12/29 21:14:12 fgsch Exp $
# $OpenBSD: Makefile,v 1.7 2004/04/23 20:29:20 jcs Exp $
PKGNAME= wmwave-0.4
PKGNAME= wmwave-0.4p1
DISTNAME= wmwave-0-4
CATEGORIES= net x11 x11/windowmaker
@ -14,8 +14,6 @@ HOMEPAGE= http://www.schuermann.org/~dockapps/
MASTER_SITES= ftp://rt.fm/pub/wmwave/
EXTRACT_SUFX= .tgz
MAINTAINER= Joshua Stein <jcs@rt.fm>
USE_X11= Yes
NO_REGRESS= Yes
WRKDIST= ${WRKDIR}/wmwave

View File

@ -1,6 +1,6 @@
$OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
--- wmwave.c.orig Fri Aug 20 08:44:21 1999
+++ wmwave.c Fri Aug 17 09:35:36 2001
$OpenBSD: patch-wmwave_wmwave_c,v 1.3 2004/04/23 20:29:20 jcs Exp $
--- wmwave.c.orig 1999-08-20 06:44:21.000000000 -0700
+++ wmwave.c 2004-04-22 13:22:47.000000000 -0700
@@ -32,7 +32,6 @@
*
*/
@ -29,7 +29,7 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
#include "wmgeneral.h"
@@ -67,6 +72,9 @@
@@ -67,6 +72,9 @@ int wmwave_mask_width = 64;
int wmwave_mask_height = 64;
#define WMWAVE_VERSION "0.4"
@ -39,7 +39,7 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
int update_rate=100000;
@@ -75,8 +83,8 @@
@@ -75,8 +83,8 @@ char *ProgName;
time_t curtime;
time_t prevtime;
@ -50,7 +50,7 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
void usage(void);
void printversion(void);
@@ -86,272 +94,268 @@
@@ -86,272 +94,270 @@ void wmwave_routine(int, char **);
void DrawBar(float percent, int dx, int dy);
void DrawGreenBar(float percent, int dx, int dy);
@ -65,6 +65,7 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
-}
+ int tx;
+ percent = abs(percent);
+ tx = (float)((float)54 * ((float)percent / (float)100.0));
+ copyXPMArea(67, 36, tx, 4, dx, dy);
+ copyXPMArea(67, 43, 54-tx, 4, dx+tx, dy);
@ -78,6 +79,7 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
- copyXPMArea(67, 43, 54-tx, 4, dx+tx, dy);
+ int tx;
+
+ percent = abs(percent);
+ tx = (float)((float)54 * ((float)percent / (float)100.0));
+ copyXPMArea(67, 58, tx, 4, dx, dy);
+ copyXPMArea(67, 43, 54-tx, 4, dx+tx, dy);
@ -320,17 +322,15 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
- wmwave_routine(argc, argv);
-
- return 0;
-}
-
-/*
- * Main loop
- */
+
+ wmwave_routine(argc, argv);
+
+ return 0;
+}
+
}
-/*
- * Main loop
- */
+/* Main loop */
void wmwave_routine(int argc, char **argv) {
- XEvent Event;
@ -390,11 +390,6 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
-
- usleep(update_rate);
- }
-}
-
-/*
- * Blits a string at given co-ordinates
- */
+
+ while (1) {
+ curtime = time(0);
@ -424,8 +419,11 @@ $OpenBSD: patch-wmwave_wmwave_c,v 1.2 2001/08/17 16:04:24 naddy Exp $
+ }
+ usleep(update_rate);
+ }
+}
+
}
-/*
- * Blits a string at given co-ordinates
- */
+/* Blits a string at given co-ordinates */
void BlitString(char *name, int x, int y) {
- int i;