patch-lbdb_lib_sh_in 788 B

123456789101112131415161718192021222324252627282930
  1. $OpenBSD: patch-lbdb_lib_sh_in,v 1.2 2009/10/10 10:48:49 sthen Exp $
  2. --- lbdb_lib.sh.in.orig Sun Aug 13 10:53:21 2006
  3. +++ lbdb_lib.sh.in Sat Oct 10 03:10:21 2009
  4. @@ -57,24 +57,7 @@ lbdb_hostname()
  5. elif test -f /etc/mailname; then
  6. hn=`cat /etc/mailname`
  7. else
  8. - hn=""
  9. - if test -r /etc/resolv.conf ; then
  10. - hn="`sed -n -e 's/^[ ]*domain[ ]\{1,\}\([^ ]*\)/\1/p' /etc/resolv.conf`"
  11. - if test "x$hn" = "x" ; then
  12. - hn="`sed -n -e 's/^[ ]*search[ ]\{1,\}\([^ ]*\)/\1/p' /etc/resolv.conf`"
  13. - fi
  14. - fi
  15. - if test "x$hn" = "x" ; then
  16. - hn=`lbdb_hn_sendmail`
  17. - if test "x$hn" = "xNONE" ; then
  18. - for i in /etc/HOSTNAME /etc/hostname ; do
  19. - if test -f $i ; then
  20. - hn="`cat $i`"
  21. - break;
  22. - fi
  23. - done
  24. - fi
  25. - fi
  26. + hn=`hostname`
  27. fi
  28. echo "$hn"
  29. }