aboutsummaryrefslogtreecommitdiffhomepage
path: root/expand.c
diff options
context:
space:
mode:
authorGravatar axel <axel@liljencrantz.se>2007-01-10 02:47:05 +1000
committerGravatar axel <axel@liljencrantz.se>2007-01-10 02:47:05 +1000
commita3aba0269d4c25f7a701383a743482dfac54c16d (patch)
tree150ddaaee4d6b8a9d29320fe91a75c42e79af6c1 /expand.c
parente1f4aa5fcdf04b9a07ed2c892c71c37ff815070d (diff)
Make it possible to cancel a long-winded wildcard match by pressing ^C
darcs-hash:20070109164705-ac50b-d8bf2c22e9ecb6bccec6892da266016dcae79a4c.gz
Diffstat (limited to 'expand.c')
-rw-r--r--expand.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/expand.c b/expand.c
index f0a973fd..8088e457 100644
--- a/expand.c
+++ b/expand.c
@@ -1747,6 +1747,15 @@ int expand_string( void *context,
al_truncate( out, 0 );
break;
}
+
+ case -1:
+ {
+ al_foreach( out, &free );
+ al_destroy( in );
+ al_destroy( out );
+ return EXPAND_ERROR;
+ }
+
}
}
else