diff options
| author | Jason Rumney | 2008-04-10 11:38:15 +0000 |
|---|---|---|
| committer | Jason Rumney | 2008-04-10 11:38:15 +0000 |
| commit | 40a339c881b095a5dd5508a1ef0d7bdb02cdec5f (patch) | |
| tree | b013096237f2a08fa2b8e115f84dd736eb51156c | |
| parent | 2b69ccfd469e67f772920e52ef52fa5aa1cbef02 (diff) | |
| download | emacs-40a339c881b095a5dd5508a1ef0d7bdb02cdec5f.tar.gz emacs-40a339c881b095a5dd5508a1ef0d7bdb02cdec5f.zip | |
(logon_network_drive): Also logon to remote drives that
are mapped to drive letters.
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/w32.c | 7 |
2 files changed, 11 insertions, 1 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 317a67c37d9..f36731450d4 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2008-04-10 Jason Rumney <jasonr@gnu.org> | ||
| 2 | |||
| 3 | * w32.c (logon_network_drive): Also logon to remote drives that | ||
| 4 | are mapped to drive letters. | ||
| 5 | |||
| 1 | 2008-04-10 Glenn Morris <rgm@gnu.org> | 6 | 2008-04-10 Glenn Morris <rgm@gnu.org> |
| 2 | 7 | ||
| 3 | * xdisp.c (truncate-partial-width-windows): Doc fix. | 8 | * xdisp.c (truncate-partial-width-windows): Doc fix. |
| @@ -2046,10 +2046,15 @@ logon_network_drive (const char *path) | |||
| 2046 | NETRESOURCE resource; | 2046 | NETRESOURCE resource; |
| 2047 | char share[MAX_PATH]; | 2047 | char share[MAX_PATH]; |
| 2048 | int i, n_slashes; | 2048 | int i, n_slashes; |
| 2049 | char drive[4]; | ||
| 2050 | |||
| 2051 | sprintf (drive, "%c:\\", path[0]); | ||
| 2049 | 2052 | ||
| 2050 | /* Only logon to networked drives. */ | 2053 | /* Only logon to networked drives. */ |
| 2051 | if (!IS_DIRECTORY_SEP (path[0]) || !IS_DIRECTORY_SEP (path[1])) | 2054 | if ((!IS_DIRECTORY_SEP (path[0]) || !IS_DIRECTORY_SEP (path[1])) |
| 2055 | && GetDriveType (drive) != DRIVE_REMOTE) | ||
| 2052 | return; | 2056 | return; |
| 2057 | |||
| 2053 | n_slashes = 2; | 2058 | n_slashes = 2; |
| 2054 | strncpy (share, path, MAX_PATH); | 2059 | strncpy (share, path, MAX_PATH); |
| 2055 | /* Truncate to just server and share name. */ | 2060 | /* Truncate to just server and share name. */ |