SOURCES: sendEmail-get_hostname.patch (NEW) - fix get_hostname

areq areq at pld-linux.org
Sun Nov 25 20:29:37 CET 2007


Author: areq                         Date: Sun Nov 25 19:29:37 2007 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- fix get_hostname

---- Files affected:
SOURCES:
   sendEmail-get_hostname.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: SOURCES/sendEmail-get_hostname.patch
diff -u /dev/null SOURCES/sendEmail-get_hostname.patch:1.1
--- /dev/null	Sun Nov 25 20:29:37 2007
+++ SOURCES/sendEmail-get_hostname.patch	Sun Nov 25 20:29:32 2007
@@ -0,0 +1,12 @@
+diff -Nur sendEmail-v1.55.org/sendEmail sendEmail-v1.55/sendEmail
+--- sendEmail-v1.55.org/sendEmail	2006-12-14 03:05:33.000000000 +0000
++++ sendEmail-v1.55/sendEmail	2007-11-25 19:22:46.051797559 +0000
+@@ -1021,7 +1021,7 @@
+     ## If that didn't get us a hostname, try a few other things
+     else {
+         ## Windows systems
+-        if ($^O !~ /win/i) {
++        if ($^O =~ /win/i) {
+             if ($ENV{'COMPUTERNAME'}) { $hostname = $ENV{'COMPUTERNAME'}; }
+             if (!$hostname) { $hostname = gethostbyname('localhost'); }
+             if (!$hostname) { chomp($hostname = `hostname 2> NUL`) };
================================================================


More information about the pld-cvs-commit mailing list