Changeset 714 for trunk/src/gmake/kmkbuiltin/mv.c
- Timestamp:
- Dec 14, 2006, 2:38:40 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gmake/kmkbuiltin/mv.c
r627 r714 45 45 #include <sys/cdefs.h> 46 46 __FBSDID("$FreeBSD: src/bin/mv/mv.c,v 1.46 2005/09/05 04:36:08 csjp Exp $"); 47 #endif 47 #endif 48 48 49 49 #include <sys/types.h> 50 50 #ifndef _MSC_VER 51 #ifndef __OS2__ 51 52 #include <sys/acl.h> 53 #endif 52 54 #include <sys/param.h> 53 55 #include <sys/time.h> … … 62 64 #ifndef _MSC_VER 63 65 #include <grp.h> 64 #endif 66 #endif 65 67 #include <limits.h> 66 68 #ifndef _MSC_VER 67 69 #include <paths.h> 68 70 #include <pwd.h> 69 #endif 71 #endif 70 72 #include <stdio.h> 71 73 #include <stdlib.h> … … 88 90 static int fastcopy(char *, char *, struct stat *); 89 91 static int copy(char *, char *); 90 #endif 92 #endif 91 93 static int usage(void); 92 94 93 95 #if !defined(__FreeBSD__) && !defined(__APPLE__) 94 static const char *user_from_uid(unsigned long id, int x) 96 # ifdef __OS2__ 97 static 98 # endif 99 const char *user_from_uid(uid_t id, int x) 95 100 { 96 101 static char s_buf[64]; … … 98 103 return s_buf; 99 104 } 100 static const char *group_from_gid(unsigned long id, int x) 105 # ifdef __OS2__ 106 static 107 # endif 108 const char *group_from_gid(gid_t id, int x) 101 109 { 102 110 static char s_buf[64]; … … 178 186 #else 179 187 if (!baselen || *(endp - 1) != '/') { 180 #endif 188 #endif 181 189 *endp++ = '/'; 182 190 ++baselen; … … 198 206 while (p != *argv && p[-1] != '/') 199 207 --p; 200 #endif 208 #endif 201 209 202 210 if ((baselen + (len = strlen(p))) >= PATH_MAX) { … … 273 281 } 274 282 } 275 #endif 283 #endif 276 284 277 285 if (errno == EXDEV) { … … 303 311 } 304 312 } 305 #endif 313 #endif 306 314 } else { 307 315 warn("rename %s to %s", from, to); … … 321 329 return (S_ISREG(sb.st_mode) ? 322 330 fastcopy(from, to, &sb) : copy(from, to)); 323 #endif 331 #endif 324 332 } 325 333
Note:
See TracChangeset
for help on using the changeset viewer.