The Samba-Bugzilla – Attachment 2813 Details for
Bug 2489
utmp hostname logging on Solaris 9
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Portable patch which detects and corrects usage of ut_host in utmpx
samba_utmpx.patch (text/plain), 1.64 KB, created by
David Gajewski
on 2007-07-12 10:51:42 UTC
(
hide
)
Description:
Portable patch which detects and corrects usage of ut_host in utmpx
Filename:
MIME Type:
Creator:
David Gajewski
Created:
2007-07-12 10:51:42 UTC
Size:
1.64 KB
patch
obsolete
>diff -ur samba-3.0.25b/source/configure.in samba-3.0.25b_utmpx/source/configure.in >--- samba-3.0.25b/source/configure.in Wed May 23 11:29:20 2007 >+++ samba-3.0.25b_utmpx/source/configure.in Mon Jul 9 10:58:38 2007 >@@ -2330,6 +2330,15 @@ > AC_DEFINE(HAVE_UX_UT_SYSLEN,1,[Whether the utmpx struct has a property ut_syslen]) > fi > >+AC_CACHE_CHECK([for ut_host in utmpx],samba_cv_HAVE_UX_UT_HOST,[ >+AC_TRY_COMPILE([#include <sys/types.h> >+#include <utmpx.h>], >+[struct utmpx ux; ux.ut_host[0] = 'a';], >+samba_cv_HAVE_UX_UT_HOST=yes,samba_cv_HAVE_UX_UT_HOST=no,samba_cv_HAVE_UX_UT_HOST=cross)]) >+if test x"$samba_cv_HAVE_UX_UT_HOST" = x"yes"; then >+ AC_DEFINE(HAVE_UX_UT_HOST,1,[Whether the utmpx struct has a property ut_host]) >+fi >+ > fi > # end utmp details > >diff -ur samba-3.0.25b/source/include/config.h.in samba-3.0.25b_utmpx/source/include/config.h.in >--- samba-3.0.25b/source/include/config.h.in Tue Jun 26 15:35:51 2007 >+++ samba-3.0.25b_utmpx/source/include/config.h.in Mon Jul 9 10:58:38 2007 >@@ -1901,6 +1901,9 @@ > /* Whether the utmpx struct has a property ut_syslen */ > #undef HAVE_UX_UT_SYSLEN > >+/* Whether the utmpx struct has a property ut_host */ >+#undef HAVE_UX_UT_HOST >+ > /* Define to 1 if you have the <valgrind.h> header file. */ > #undef HAVE_VALGRIND_H > >diff -ur samba-3.0.25b/source/smbd/utmp.c samba-3.0.25b_utmpx/source/smbd/utmp.c >--- samba-3.0.25b/source/smbd/utmp.c Fri Feb 25 12:59:26 2005 >+++ samba-3.0.25b_utmpx/source/smbd/utmp.c Mon Jul 9 10:58:38 2007 >@@ -410,7 +410,7 @@ > else > ux.ut_syslen = 0; > #endif >-#if defined(HAVE_UT_UT_HOST) >+#if defined(HAVE_UX_UT_HOST) > utmp_strcpy(ux.ut_host, hostname, sizeof(ux.ut_host)); > #endif >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 2489
: 2813