mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
(logon_network_drive): Also logon to remote drives that
are mapped to drive letters.
This commit is contained in:
parent
2b69ccfd46
commit
40a339c881
2 changed files with 11 additions and 1 deletions
|
|
@ -1,3 +1,8 @@
|
|||
2008-04-10 Jason Rumney <jasonr@gnu.org>
|
||||
|
||||
* w32.c (logon_network_drive): Also logon to remote drives that
|
||||
are mapped to drive letters.
|
||||
|
||||
2008-04-10 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* xdisp.c (truncate-partial-width-windows): Doc fix.
|
||||
|
|
|
|||
|
|
@ -2046,10 +2046,15 @@ logon_network_drive (const char *path)
|
|||
NETRESOURCE resource;
|
||||
char share[MAX_PATH];
|
||||
int i, n_slashes;
|
||||
char drive[4];
|
||||
|
||||
sprintf (drive, "%c:\\", path[0]);
|
||||
|
||||
/* Only logon to networked drives. */
|
||||
if (!IS_DIRECTORY_SEP (path[0]) || !IS_DIRECTORY_SEP (path[1]))
|
||||
if ((!IS_DIRECTORY_SEP (path[0]) || !IS_DIRECTORY_SEP (path[1]))
|
||||
&& GetDriveType (drive) != DRIVE_REMOTE)
|
||||
return;
|
||||
|
||||
n_slashes = 2;
|
||||
strncpy (share, path, MAX_PATH);
|
||||
/* Truncate to just server and share name. */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue