summaryrefslogtreecommitdiffstats
path: root/gridsel.c
diff options
context:
space:
mode:
authorAnselm R. Garbe <garbeam@wmii.de>2006-07-11 18:19:01 +0200
committerAnselm R. Garbe <garbeam@wmii.de>2006-07-11 18:19:01 +0200
commitb1669b5c48f71c9a7a919dbf09a1af527c62f69a (patch)
treef94f1018357afe5abef9cde46a80d16a9676010f /gridsel.c
parentadded bar event timer (diff)
downloaddwm-b1669b5c48f71c9a7a919dbf09a1af527c62f69a.tar.gz
dwm-b1669b5c48f71c9a7a919dbf09a1af527c62f69a.zip
removed unnecessary sel stuff
Diffstat (limited to 'gridsel.c')
-rw-r--r--gridsel.c47
1 files changed, 0 insertions, 47 deletions
diff --git a/gridsel.c b/gridsel.c
deleted file mode 100644
index c76105e..0000000
--- a/gridsel.c
+++ /dev/null
@@ -1,47 +0,0 @@
1/*
2 * (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
3 * See LICENSE file for license details.
4 */
5
6#include <stdlib.h>
7#include <stdio.h>
8#include <string.h>
9
10#include <util.h>
11
12static char version[] = "gridsel - " VERSION ", (C)opyright MMVI Anselm R. Garbe\n";
13
14static void
15usage()
16{
17 fprintf(stderr, "%s\n", "usage: gridsel [-v]\n");
18 exit(1);
19}
20
21int
22main(int argc, char **argv)
23{
24 unsigned char *data;
25 unsigned long i, offset, len, remain;
26
27 /* command line args */
28 if(argc > 1) {
29 if(!strncmp(argv[1], "-v", 3)) {
30 fprintf(stdout, "%s", version);
31 exit(0);
32 } else
33 usage();
34 }
35 len = offset = remain = 0;
36 do {
37 data = getselection(offset, &len, &remain);
38 for(i = 0; i < len; i++)
39 putchar(data[i]);
40 offset += len;
41 free(data);
42 }
43 while(remain);
44 if(offset)
45 putchar('\n');
46 return 0;
47}