commit b55842c2243c41850b839f900fe333ff3dbef2ab
Author: Richard Hughes <richard@hughsie.com>
Date: Tue Apr 14 13:32:10 2009 +0100
bugfix: still use command not found for commands one character long
diff --git a/contrib/command-not-found/pk-command-not-found.c b/contrib/command-not-found/pk-command-not-found.c
index 2df80e9..f6aba8e 100644
--- a/contrib/command-not-found/pk-command-not-found.c
+++ b/contrib/command-not-found/pk-command-not-found.c
@@ -545,11 +545,12 @@ main (int argc, char *argv[])
/* get policy config */
pk_cnf_get_config (&config);
- /* generate swizzles */
+ /* get length */
len = egg_strlen (argv[1], 1024);
- if (len < 2)
+ if (len < 1)
goto out;
+ /* generate swizzles */
array = pk_cnf_find_alternatives (argv[1], len);
/* TRANSLATORS: the prefix of all the output telling the user why it's not executing */