File src/utils/utils.c changed (mode: 100644) (index 779bc438b..3889e6b6c) |
58 |
58 |
|
|
59 |
59 |
#ifdef _WIN32 |
#ifdef _WIN32 |
60 |
60 |
static void unquote(char quoted[]); |
static void unquote(char quoted[]); |
61 |
|
#else |
|
62 |
|
static int is_line_spec(const char str[]); |
|
63 |
61 |
#endif |
#endif |
|
62 |
|
static int is_line_spec(const char str[]); |
64 |
63 |
|
|
65 |
64 |
int |
int |
66 |
65 |
vifm_system(char command[]) |
vifm_system(char command[]) |
|
... |
... |
parse_file_spec(const char spec[], int *line_num) |
560 |
559 |
|
|
561 |
560 |
#ifdef _WIN32 |
#ifdef _WIN32 |
562 |
561 |
colon = strchr(spec + (is_path_absolute(spec) ? 2 : 0), ':'); |
colon = strchr(spec + (is_path_absolute(spec) ? 2 : 0), ':'); |
|
562 |
|
if(colon != NULL && !is_line_spec(colon + 1)) |
|
563 |
|
{ |
|
564 |
|
colon = NULL; |
|
565 |
|
} |
563 |
566 |
#else |
#else |
564 |
567 |
colon = strchr(spec, ':'); |
colon = strchr(spec, ':'); |
565 |
568 |
while(colon != NULL) |
while(colon != NULL) |
|
... |
... |
parse_file_spec(const char spec[], int *line_num) |
604 |
607 |
return replace_tilde(path_buf); |
return replace_tilde(path_buf); |
605 |
608 |
} |
} |
606 |
609 |
|
|
607 |
|
#ifndef _WIN32 |
|
608 |
|
|
|
609 |
610 |
/* Checks whether str points to a valid line number. Returns non-zero if so, |
/* Checks whether str points to a valid line number. Returns non-zero if so, |
610 |
611 |
* otherwise zero is returned. */ |
* otherwise zero is returned. */ |
611 |
612 |
static int |
static int |
|
... |
... |
is_line_spec(const char str[]) |
617 |
618 |
return (endptr != str && errno == 0 && *endptr == ':'); |
return (endptr != str && errno == 0 && *endptr == ':'); |
618 |
619 |
} |
} |
619 |
620 |
|
|
620 |
|
#endif |
|
621 |
|
|
|
622 |
621 |
int |
int |
623 |
622 |
is_graphics_viewer(const char viewer[]) |
is_graphics_viewer(const char viewer[]) |
624 |
623 |
{ |
{ |