[hackers] [lsw] cleanup || Connor Lane Smith

From: <hg_AT_suckless.org>
Date: Sat, 18 Jun 2011 05:55:00 +0200 (CEST)

changeset: 14:4426592fcac8
tag: tip
user: Connor Lane Smith <cls_AT_lubutu.com>
date: Sat Jun 18 04:54:53 2011 +0100
files: README lsw.1 lsw.c
description:
cleanup

diff -r 3c024cc9cbbf -r 4426592fcac8 README
--- a/README Sat Jun 18 04:30:21 2011 +0100
+++ b/README Sat Jun 18 04:54:53 2011 +0100
@@ -1,6 +1,6 @@
-lsw - list window titles
-========================
-Prints all window titles of DISPLAY to standard output.
+lsw - list windows
+==================
+lsw prints the title and XID of windows to stdout.
 
 
 Requirements
diff -r 3c024cc9cbbf -r 4426592fcac8 lsw.1
--- a/lsw.1 Sat Jun 18 04:30:21 2011 +0100
+++ b/lsw.1 Sat Jun 18 04:54:53 2011 +0100
@@ -1,9 +1,9 @@
 .TH LSW 1 lsw\-VERSION
 .SH NAME
-lsw \- list window titles
+lsw \- list windows
 .SH SYNOPSIS
 .B lsw
-.RI [ windows ...]
+.RI [ window ...]
 .SH DESCRIPTION
 .B lsw
 prints the title and XID of each child of each
diff -r 3c024cc9cbbf -r 4426592fcac8 lsw.c
--- a/lsw.c Sat Jun 18 04:30:21 2011 +0100
+++ b/lsw.c Sat Jun 18 04:54:53 2011 +0100
@@ -2,7 +2,6 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-#include <X11/Xatom.h>
 #include <X11/Xlib.h>
 #include <X11/Xutil.h>
 
@@ -17,7 +16,7 @@
         int i;
 
         if(!(dpy = XOpenDisplay(NULL))) {
- fputs("lsw: cannot open display\n", stderr);
+ fprintf(stderr, "%s: cannot open display\n", argv[0]);
                 exit(EXIT_FAILURE);
         }
         netwmname = XInternAtom(dpy, "_NET_WM_NAME", False);
Received on Sat Jun 18 2011 - 05:55:00 CEST

This archive was generated by hypermail 2.2.0 : Sat Jun 18 2011 - 06:00:08 CEST