[Pkg-wmaker-commits] [wmtime] 39/101: debian/patches/remove_unused_variables: Avoid compiler warning.

Doug Torrance dtorrance-guest at moszumanska.debian.org
Mon Aug 24 23:59:27 UTC 2015


This is an automated email from the git hooks/post-receive script.

dtorrance-guest pushed a commit to branch master
in repository wmtime.

commit 47ee6bcf3a462a8753bc144d3177e2588b59a858
Author: Doug Torrance <dtorrance at monmouthcollege.edu>
Date:   Tue Aug 19 01:28:54 2014 -0500

    debian/patches/remove_unused_variables: Avoid compiler warning.
---
 debian/patches/remove_unused_variables.patch | 36 ++++++++++++++++++++++++++++
 debian/patches/series                        |  1 +
 2 files changed, 37 insertions(+)

diff --git a/debian/patches/remove_unused_variables.patch b/debian/patches/remove_unused_variables.patch
new file mode 100644
index 0000000..daa35dd
--- /dev/null
+++ b/debian/patches/remove_unused_variables.patch
@@ -0,0 +1,36 @@
+Description: Remove unused variables.
+ This patch removes the unused variables nexttime and old_time_struct to avoid
+ a warning when -Wunused-but-set-variable is passed.
+Author: Doug Torrance <dtorrance at monmouthcollege.edu>
+Last-Update: 2014-08-19
+
+--- a/wmtime/wmtime.c
++++ b/wmtime/wmtime.c
+@@ -231,11 +231,9 @@
+ 	int			but_stat = -1;
+ 
+ 	struct tm	*time_struct;
+-	struct tm	old_time_struct;
+ 
+ 	long		starttime;
+ 	long		curtime;
+-	long		nexttime;
+ 
+ 	char		*conffile = NULL;
+ 
+@@ -273,7 +271,6 @@
+ 	AddMouseRegion(1, 5, 5, 58, 46);
+ 
+ 	starttime = time(0);
+-	nexttime = starttime + 1;
+ 
+ 	curtime = time(0);
+ 	time_struct = localtime(&curtime);
+@@ -283,7 +280,6 @@
+ 
+ 		waitpid(0, NULL, WNOHANG);
+ 		
+-		old_time_struct = *time_struct;
+ 		time_struct = localtime(&curtime);
+ 
+ 
diff --git a/debian/patches/series b/debian/patches/series
index ad4365f..b6d2633 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
 rm-force-in-make-clean.patch
+remove_unused_variables.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-wmaker/wmtime.git



More information about the Pkg-wmaker-commits mailing list