Package: wmclock
Version: 1.0.14-1
Severity: minor
Tags: upstream patch

Dear Maintainer,

When the -year option is selected, the 4th digit of the year is used in place
of the 2nd digit.  This is due to a typo in the showYear function.

I have attached a patch to fix this problem.

-- System Information:
Debian Release: wheezy/sid
  APT prefers raring-updates
  APT policy: (500, 'raring-updates'), (500, 'raring-security'), (500, 
'raring'), (100, 'raring-backports')
Architecture: i386 (i686)

Kernel: Linux 3.8.0-19-generic (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages wmclock depends on:
ii  libc6     2.17-0ubuntu5
ii  libx11-6  2:1.5.0-1ubuntu1
ii  libxext6  2:1.3.1-2
ii  libxpm4   1:3.5.10-1

wmclock recommends no packages.

wmclock suggests no packages.

-- no debconf information
--- wmclock-1.0.14.orig/wmclock.c	2013-09-20 16:03:20.472817384 -0500
+++ wmclock-1.0.14/wmclock.c	2013-09-20 15:55:01.000000000 -0500
@@ -490,7 +490,7 @@ void showYear(void)
    XCopyArea(dpy, led.pixmap, visible.pixmap, normalGC,
 	     digitXOffset , digitYOffset, LED_NUM_WIDTH, LED_NUM_HEIGHT,
 	     xPos[DIGIT_1_X_POS], yPos[DIGIT_Y_POS]);
-   digitXOffset = LED_NUM_WIDTH * ((year % 100) % 10);
+   digitXOffset = LED_NUM_WIDTH * ((year / 100) % 10);
    XCopyArea(dpy, led.pixmap, visible.pixmap, normalGC,
 	     digitXOffset , digitYOffset, LED_NUM_WIDTH, LED_NUM_HEIGHT,
 	     xPos[DIGIT_2_X_POS], yPos[DIGIT_Y_POS]);

Reply via email to