Index: openafs/src/WINNT/client_exp/gui2fs.cpp
diff -c openafs/src/WINNT/client_exp/gui2fs.cpp:1.2.8.1 openafs/src/WINNT/client_exp/gui2fs.cpp:1.2.8.2
*** openafs/src/WINNT/client_exp/gui2fs.cpp:1.2.8.1	Wed Dec  4 09:25:53 2002
--- openafs/src/WINNT/client_exp/gui2fs.cpp	Sat Dec 14 23:34:45 2002
***************
*** 1223,1228 ****
--- 1223,1304 ----
  	return (code==0);
  }
  
+ BOOL RemoveSymlink(const char * linkName)
+ {
+ 	BOOL error = FALSE;
+     INT code=0;
+     struct ViceIoctl blob;
+     char tbuffer[1024];
+     char lsbuffer[1024];
+ 	char tpbuffer[1024];
+     char *tp;
+     
+ 	tp = (char *) strrchr(linkName, '\\');
+ 	if (!tp)
+ 	    tp = (char *) strrchr(linkName, '/');
+ 	if (tp) {
+ 	    strncpy(tbuffer, linkName, code=tp-linkName+1);  /* the dir name */
+             tbuffer[code] = 0;
+ 	    tp++;   /* skip the slash */
+ 	}
+ 	else {
+ 	    fs_ExtractDriveLetter(linkName, tbuffer);
+ 	    strcat(tbuffer, ".");
+          fs_StripDriveLetter(tp, tpbuffer, 0);
+ 		 tp=tpbuffer;
+ 	}
+ 	blob.in = tp;
+ 	blob.in_size = strlen(tp)+1;
+ 	blob.out = lsbuffer;
+ 	blob.out_size = sizeof(lsbuffer);
+ 	code = pioctl(tbuffer, VIOC_LISTSYMLINK, &blob, 0);
+ 	if (code)
+ 		return FALSE;
+ 	blob.out_size = 0;
+ 	blob.in = tp;
+ 	blob.in_size = strlen(tp)+1;
+ 	return (pioctl(tbuffer, VIOC_DELSYMLINK, &blob, 0)==0);
+ }
+ 
+ BOOL IsSymlink(const char * true_name)
+ {
+     char parent_dir[MAXSIZE];		/*Parent directory of true name*/
+ 	char strip_name[MAXSIZE];
+     struct ViceIoctl blob;
+ 	char *last_component;
+     int code;
+ 	last_component = (char *) strrchr(true_name, '\\');
+ 	if (!last_component)
+ 	    last_component = (char *) strrchr(true_name, '/');
+ 	if (last_component) {
+ 	    /*
+ 	     * Found it.  Designate everything before it as the parent directory,
+ 	     * everything after it as the final component.
+ 	     */
+ 	    strncpy(parent_dir, true_name, last_component - true_name + 1);
+ 	    parent_dir[last_component - true_name + 1] = 0;
+ 	    last_component++;   /*Skip the slash*/
+ 	}
+ 	else {
+ 	    /*
+ 	     * No slash appears in the given file name.  Set parent_dir to the current
+ 	     * directory, and the last component as the given name.
+ 	     */
+ 	    fs_ExtractDriveLetter(true_name, parent_dir);
+ 	    strcat(parent_dir, ".");
+ 	    last_component = strip_name;
+         fs_StripDriveLetter(true_name, strip_name, sizeof(strip_name));
+ 	}
+ 
+ 	blob.in = last_component;
+ 	blob.in_size = strlen(last_component)+1;
+ 	blob.out_size = MAXSIZE;
+ 	blob.out = space;
+ 	memset(space, 0, MAXSIZE);
+ 	code = pioctl(parent_dir, VIOC_LISTSYMLINK, &blob, 1);
+ 	return (code==0);
+ }
+ 
  
  /*
   * Delete AFS mount points.  Variables are used as follows:
Index: openafs/src/WINNT/client_exp/shell_ext.cpp
diff -c openafs/src/WINNT/client_exp/shell_ext.cpp:1.2.8.2 openafs/src/WINNT/client_exp/shell_ext.cpp:1.2.8.3
*** openafs/src/WINNT/client_exp/shell_ext.cpp:1.2.8.2	Tue Dec 10 17:55:57 2002
--- openafs/src/WINNT/client_exp/shell_ext.cpp	Sat Dec 14 23:34:45 2002
***************
*** 14,19 ****
--- 14,20 ----
  
  #include <afxpriv.h>
  #include "stdafx.h"
+ #include <atlconv.h>
  #include <sys/types.h>
  #include <sys/stat.h>
  #include "afs_shl_ext.h"
