From e5ebb19fd49647d2c804ee3399b928b877865c7d Mon Sep 17 00:00:00 2001 From: John Kohl Date: Fri, 17 Nov 1989 04:58:26 +0000 Subject: prevent use of uninitialized variables (problems with centering z-grams) --- zwgc/xshow.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'zwgc/xshow.c') diff --git a/zwgc/xshow.c b/zwgc/xshow.c index 87a0266..291c75f 100644 --- a/zwgc/xshow.c +++ b/zwgc/xshow.c @@ -328,16 +328,18 @@ void fixup_and_draw(dpy, style, auxblocks, blocks, num, lines, numlines, sscanf(geometry, "%c%[0123456789c]%c%[0123456789c]", &xfrom, xpos, &yfrom, ypos); - if (xpos[0]=='c') + if (xpos[0]=='c') { gram_xalign = 0; - else + gram_xpos = 0; + } else gram_xpos = atoi(xpos); if (xfrom=='-') gram_xalign *= -1; - if (ypos[0]=='c') + if (ypos[0]=='c') { gram_yalign = 0; - else + gram_ypos = 0; + } else gram_ypos = atoi(ypos); if (yfrom=='-') gram_yalign *= -1; -- cgit v1.2.3