Hi again.

Ian Jackson writes ("Re: unclutter: ftbfs with GCC-14"):
> I've just noticed this bug (my scripting was broken).  I'm not in a
> position to fix it before the autoremoval but I iintend to NMU it in a
> week or so.

Here's the patch.  I've chosen to try to retain the original style and
not convert any of the functions I touched to ANSI C syntax.

I'll be uploading this shortly and will file a separate bug with the
nmudiff.

Thanks,
Ian.

>From 5ec60ce56eb580acffd7b384a0e8b8a59b73b655 Mon Sep 17 00:00:00 2001
From: Ian Jackson <ijack...@chiark.greenend.org.uk>
Date: Thu, 15 Aug 2024 20:10:04 +0100
Subject: [PATCH] Fix implicit ints in function declarations

Closes: #1075602
---
 unclutter.c | 7 ++++++-
 vroot.h     | 1 +
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/unclutter.c b/unclutter.c
index c016663..de5a971 100644
--- a/unclutter.c
+++ b/unclutter.c
@@ -32,10 +32,12 @@
 #include <regex.h>
 
 char *progname;
+void
 pexit(str)char *str;{
     fprintf(stderr,"%s: %s\n",progname,str);
     exit(1);
 }
+void
 usage(){
     pexit("usage:\n\
        -display <display>\n\
@@ -93,6 +95,7 @@ regex_t *nc_re = 0;     /* regex for list of classes/names to 
avoid */
  * return true if window has a wm_name (class) and the start of it matches
  * one of the given names (classes) to avoid
  */
+int
 nameinlist(display,window)
 Display *display;
 Window window;
@@ -131,6 +134,7 @@ Window window;
 /*
  * create a small 1x1 curssor with all pixels masked out on the given screen.
  */
+Cursor
 createnullcursor(display,root)
 Display *display;
 Window root;
@@ -155,7 +159,8 @@ Window root;
     return cursor;
 }
 
-main(argc,argv)char **argv;{
+int
+main(argc,argv)char **argv; int argc;{
     Display *display;
     int screen,oldx = -99,oldy = -99,numscreens;
     int doroot = 0, jitter = 0, usegrabmethod = 0, waitagain = 0,
diff --git a/vroot.h b/vroot.h
index 0f32668..cbe41dc 100644
--- a/vroot.h
+++ b/vroot.h
@@ -40,6 +40,7 @@
 static Window
 VirtualRootWindow(dpy, screen)
 Display *dpy;
+int screen;
 {
        static Display *save_dpy = (Display *)0;
        static int save_screen = -1;
-- 
2.20.1


-- 
Ian Jackson <ijack...@chiark.greenend.org.uk>   These opinions are my own.  

Pronouns: they/he.  If I emailed you from @fyvzl.net or @evade.org.uk,
that is a private address which bypasses my fierce spamfilter.

Reply via email to