Consider Windows paths starting with \ absolute when used with the --script option.

This commit is contained in:
david 2007-12-14 08:33:31 +00:00
parent 48dec0f9d9
commit 29109de637
2 changed files with 4 additions and 1 deletions

View file

@ -1,5 +1,8 @@
# Nmap Changelog ($Id$); -*-text-*-
o On Windows, paths beginning with \ are now considered absolute when
used with the --script option.
o Zenmap no longer double-spaces its output (by inadvertently
duplicating newlines) when viewing scan results that were saved to a
file.

View file

@ -528,7 +528,7 @@ static bool filename_is_absolute(const char *file) {
if (file[0] == '/')
return true;
#ifdef WIN32
if (file[0] != '\0' && file[1] == ':')
if ((file[0] != '\0' && file[1] == ':') || file[0] == '\\')
return true;
#endif
return false;