Commit Diff


commit - 26b1f4854972ff8e8cf1805c1cabcf82d70b422d
commit + 78a0e67f6fd44afc490886e1199117ad31291ee7
blob - 95c16741380a548d4097b616f07821d1ded177ff
blob + d952eec9e8d4409adf36c3a852924410a8f75003
--- mymenu.c
+++ mymenu.c
@@ -1213,7 +1213,7 @@ int main(int argc, char **argv) {
 
 	// if first_selected is active and the first completion is
 	// active be sure to 'expand' the text to match the selection
-	if (first_selected && cs->selected) {
+	if (first_selected && cs && cs->selected) {
 	  free(text);
 	  text = strdup(cs->completion);
 	  if (text == nil) {