1
0
Fork 0
mirror of https://github.com/davatorium/rofi.git synced 2024-11-25 13:55:34 -05:00

Fix name matching for ssh-dialog, fix bug 80.

This commit is contained in:
Dave Davenport 2014-09-01 19:52:48 +02:00
parent 5d5b4aac9f
commit 5f33d506b9

View file

@ -154,14 +154,15 @@ static char ** get_ssh ( unsigned int *length )
;
}
for ( stop = start; isalnum ( buffer[stop] ) ||
buffer[stop] == '_' ||
buffer[stop] == '.'; stop++ ) {
;
for ( stop = start; !isspace(buffer[stop]) ; stop++ ) {
// We do not want to show wildcard entries, as you cannot ssh to them.
if ( buffer[stop] == '?' || buffer[stop] == '*' ) {
stop = start;
break;
}
}
int found = 0;
if ( start == stop ) {
continue;
}