summaryrefslogtreecommitdiff
path: root/xrefresh.c
diff options
context:
space:
mode:
Diffstat (limited to 'xrefresh.c')
-rw-r--r--xrefresh.c28
1 files changed, 12 insertions, 16 deletions
diff --git a/xrefresh.c b/xrefresh.c
index 06500a3..b857ef8 100644
--- a/xrefresh.c
+++ b/xrefresh.c
@@ -51,6 +51,7 @@ SOFTWARE.
* Kitchen sink version, useful for clearing small areas and flashing the
* screen.
*/
+/* $XFree86: xc/programs/xrefresh/xrefresh.c,v 3.6 2001/12/14 20:02:15 dawes Exp $ */
#include <stdio.h>
#include <errno.h>
@@ -58,14 +59,14 @@ SOFTWARE.
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <ctype.h>
-
-char *malloc();
+#include <stdlib.h>
Window win;
char *ProgramName;
-void Syntax ()
+static void
+Syntax(void)
{
fprintf (stderr, "usage: %s [-options] [geometry] [display]\n\n",
ProgramName);
@@ -81,11 +82,10 @@ void Syntax ()
exit (1);
}
-static char *copystring (s)
- register char *s;
+static char *
+copystring(char *s)
{
int len = (s ? strlen (s) : 0) + 1;
- char *malloc();
char *retval;
retval = malloc (len);
@@ -103,8 +103,8 @@ static char *copystring (s)
* for error, no, yes.
*/
-static int parse_boolean_option (option)
- register char *option;
+static int
+parse_boolean_option(char *option)
{
static struct _booltable {
char *name;
@@ -132,10 +132,8 @@ static int parse_boolean_option (option)
* whether or not the given string is an abbreviation of the arg.
*/
-static Bool isabbreviation (arg, s, minslen)
- char *arg;
- char *s;
- int minslen;
+static Bool
+isabbreviation(char *arg, char *s, int minslen)
{
int arglen;
int slen;
@@ -169,10 +167,8 @@ struct s_pair {
{ "Root", doRoot },
{ NULL, doDefault }};
-
-main(argc, argv)
-int argc;
-char *argv[];
+int
+main(int argc, char *argv[])
{
Visual visual;
XSetWindowAttributes xswa;