SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
32
editors/xemacs21/stable/patches/patch-src_editfns_c
Normal file
32
editors/xemacs21/stable/patches/patch-src_editfns_c
Normal file
|
@ -0,0 +1,32 @@
|
|||
--- src/editfns.c.orig Sat Jul 1 07:19:57 2006
|
||||
+++ src/editfns.c Sun Jan 2 23:29:57 2011
|
||||
@@ -876,6 +876,7 @@ get_home_directory (void)
|
||||
between XEmacs and the outside world, the very moment we first get
|
||||
the data. --ben */
|
||||
int output_home_warning = 0;
|
||||
+ struct passwd *pw = NULL;
|
||||
|
||||
if (cached_home_directory == NULL)
|
||||
{
|
||||
@@ -922,6 +923,13 @@ get_home_directory (void)
|
||||
# endif
|
||||
}
|
||||
#else /* !WIN32_NATIVE */
|
||||
+ if ((pw = getpwuid(getuid())) != NULL)
|
||||
+ {
|
||||
+ cached_home_directory = pw->pw_dir;
|
||||
+ output_home_warning = 0;
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
/*
|
||||
* Unix, typically.
|
||||
* Using "/" isn't quite right, but what should we do?
|
||||
@@ -930,6 +938,7 @@ get_home_directory (void)
|
||||
*/
|
||||
cached_home_directory = (Extbyte *) "/";
|
||||
output_home_warning = 1;
|
||||
+ }
|
||||
#endif /* !WIN32_NATIVE */
|
||||
}
|
||||
if (initialized && output_home_warning)
|
Loading…
Add table
Add a link
Reference in a new issue