summaryrefslogtreecommitdiff
path: root/sysutils/libirman
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2012-10-26 20:29:15 +0000
committerjoerg <joerg@pkgsrc.org>2012-10-26 20:29:15 +0000
commitae3930b089c68e718efdfcd0d5f6609279828680 (patch)
treee81413c8be25687f2ddd89692a419477c8d05440 /sysutils/libirman
parentc35d7880c9ded9c2a2dc7b147049e9e48ae00265 (diff)
downloadpkgsrc-ae3930b089c68e718efdfcd0d5f6609279828680.tar.gz
Don't conflict with log from libm.
Diffstat (limited to 'sysutils/libirman')
-rw-r--r--sysutils/libirman/distinfo3
-rw-r--r--sysutils/libirman/patches/patch-lirmand.c65
2 files changed, 67 insertions, 1 deletions
diff --git a/sysutils/libirman/distinfo b/sysutils/libirman/distinfo
index 8abba47197f..d434c868a5b 100644
--- a/sysutils/libirman/distinfo
+++ b/sysutils/libirman/distinfo
@@ -1,5 +1,6 @@
-$NetBSD: distinfo,v 1.9 2009/02/13 22:18:01 abs Exp $
+$NetBSD: distinfo,v 1.10 2012/10/26 20:29:15 joerg Exp $
SHA1 (libirman-0.4.1c.tbz) = be8e734842d33da4f7d6949212479f693c925a12
RMD160 (libirman-0.4.1c.tbz) = 4ffeb2fd219df81051a8192ade02a7e39a3e0202
Size (libirman-0.4.1c.tbz) = 48911 bytes
+SHA1 (patch-lirmand.c) = 0963825bbe9cca927ca87889ea7a1c0941e562ee
diff --git a/sysutils/libirman/patches/patch-lirmand.c b/sysutils/libirman/patches/patch-lirmand.c
new file mode 100644
index 00000000000..92f657a80fc
--- /dev/null
+++ b/sysutils/libirman/patches/patch-lirmand.c
@@ -0,0 +1,65 @@
+$NetBSD: patch-lirmand.c,v 1.1 2012/10/26 20:29:15 joerg Exp $
+
+--- lirmand.c.orig 2012-10-26 14:22:50.000000000 +0000
++++ lirmand.c
+@@ -63,30 +63,30 @@ char *progname = "lirmand";
+
+ int lirc = 0; /* file descriptor */
+ int is_daemon = 0;
+-FILE *log = NULL;
++FILE *my_log = NULL;
+
+ FILE *open_log(void)
+ {
+ time_t t=time(NULL);
+
+- if (!log) {
+- log = fopen(LIRMAND_LOGFILE, "a");
+- if (log) {
+- fprintf(log, "%s started at %s\n", progname, ctime(&t));
++ if (!my_log) {
++ my_log = fopen(LIRMAND_LOGFILE, "a");
++ if (my_log) {
++ fprintf(my_log, "%s started at %s\n", progname, ctime(&t));
+ }
+ }
+- return log;
++ return my_log;
+ }
+
+ void close_log(void)
+ {
+ time_t t = time(NULL);
+
+- if (log) {
+- fprintf(log, "%s stopped at %s\n", progname, ctime(&t));
+- fclose(log);
++ if (my_log) {
++ fprintf(my_log, "%s stopped at %s\n", progname, ctime(&t));
++ fclose(my_log);
+ }
+- log = NULL;
++ my_log = NULL;
+ }
+
+
+@@ -99,7 +99,7 @@ int debug_printf(char *format, ...)
+ return 0;
+
+ va_start(va, format);
+- ret = vfprintf(log, format, va);
++ ret = vfprintf(my_log, format, va);
+ va_end(va);
+
+ return ret;
+@@ -114,8 +114,8 @@ int eprintf(char *format, ...)
+
+ va_start(va, format);
+ if (open_log()) {
+- ret = fprintf(log, "error: ");
+- ret += vfprintf(log, format, va);
++ ret = fprintf(my_log, "error: ");
++ ret += vfprintf(my_log, format, va);
+ }
+ if (!is_daemon) {
+ ret = fprintf(stderr, "%s: ", progname);