summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJérémie Courrèges-Anglas <jca@wxcvbn.org>2013-06-05 00:59:46 +0200
committerJérémie Courrèges-Anglas <jca@wxcvbn.org>2013-06-05 00:59:46 +0200
commit7a155e8fad801b99125a654f74a6125249da8104 (patch)
treeac59e8b5a140b8772f472af4726e627dbba097ba
parent1142b82fe4dec980846a620409bb462f765ea74f (diff)
downloadratpoison-7a155e8fad801b99125a654f74a6125249da8104.zip
contrib/sloppy.c: no need for grep(1)
-rw-r--r--contrib/sloppy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/sloppy.c b/contrib/sloppy.c
index 3656476..deeea3f 100644
--- a/contrib/sloppy.c
+++ b/contrib/sloppy.c
@@ -99,8 +99,8 @@ main (void)
char shell[256];
snprintf (shell, sizeof(shell),
- "$RATPOISON -c \"select `$RATPOISON -c 'windows %%i %%n' | "
- "grep '%ld' | awk '{print $2}'`\"",
+ "$RATPOISON -c \"select `$RATPOISON -c 'windows %%i %%n'"
+ "| awk '$1 == %ld { print $2; }'`\"",
event.xcrossing.window);
spawn (shell);
wait (NULL);