1Index: src/os_unix.c 2=================================================================== 3--- src/os_unix.c (revision 57762) 4+++ src/os_unix.c (working copy) 5@@ -584,6 +584,32 @@ 6 } 7 #endif 8 9+/* 10+ * mch_am_i_owner(name): do I own the file (or am I root) 11+ * (used to check whether .exrc should be used or not) 12+ */ 13+ 14+ int 15+mch_am_i_owner(name) 16+ char_u *name; 17+{ 18+ struct stat statb; 19+ uid_t current_uid=getuid(); 20+ 21+ if (current_uid == 0) /* Root always looks like owner */ 22+ return OK; 23+ /* Keep the #ifdef outside of stat(), it may be a macro. */ 24+#ifdef VMS 25+ if (stat((char *)vms_fixfilename(name), &statb)) 26+#else 27+ if (stat((char *)name, &statb)) 28+#endif 29+ return -1; 30+ if (getuid() == statb.st_uid) 31+ return OK; 32+ return 0; 33+} 34+ 35 void 36 mch_delay(msec, ignoreinput) 37 long msec; 38@@ -809,12 +835,6 @@ 39 if (signal_stack != NULL) 40 { 41 # ifdef HAVE_SIGALTSTACK 42-# if defined(__APPLE__) && (!defined(MAC_OS_X_VERSION_MAX_ALLOWED) \ 43- || MAC_OS_X_VERSION_MAX_ALLOWED <= 1040) 44- /* missing prototype. Adding it to osdef?.h.in doesn't work, because 45- * "struct sigaltstack" needs to be declared. */ 46- extern int sigaltstack __ARGS((const struct sigaltstack *ss, struct sigaltstack *oss)); 47-# endif 48 49 # ifdef HAVE_SS_BASE 50 sigstk.ss_base = signal_stack; 51@@ -3608,6 +3628,10 @@ 52 if (columns <= 0 || rows <= 0) 53 return FAIL; 54 55+ if (Unix2003_compat) { 56+ /* Use the -w value specified on command line */ 57+ if (p_window_unix2003) rows = p_window_unix2003; 58+ } 59 Rows = rows; 60 Columns = columns; 61 return OK; 62