trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From geor...@apache.org
Subject svn commit: r902234 [2/2] - in /incubator/trafficserver/traffic/branches/dev: ./ iocore/cache/ iocore/cluster/ iocore/eventsystem/ iocore/hostdb/ iocore/net/ libinktomi++/ proxy/ proxy/http2/ proxy/logging/ proxy/mgmt2/ proxy/mgmt2/api2/include/ proxy/...
Date Fri, 22 Jan 2010 19:17:33 GMT
Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cli2/cli_scriptpaths.h
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cli2/cli_scriptpaths.h?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cli2/cli_scriptpaths.h (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cli2/cli_scriptpaths.h Fri Jan
22 19:17:30 2010
@@ -28,18 +28,19 @@
 #define __SPI_SCRIPT_PATH__H
 
 #define INKTOMI_HOME "/home/inktomi"
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 #define DEFAULTROUTER_PATH "/etc/defaultrouter"
 #define DEFAULT_DOMAIN_PATH "/etc/defaultdomain"
 #define NETMASK_PATH "/etc/inet/netmasks"
 
-// not used by sunos
+// not used by solaris
 #define NIC_IDENTIFIER_STRING ""
 
 #define NIC_SETTINGS_FILE "/kernel/drv/iprb.conf"
 #define NIC_CHANGES_STRING "Changes Take Effect on Reboot"
 #define NIC_CONFIG_LABEL "ForceSpeedDuplex="
 #define SET_ROUTER_SCRIPT "./cli_setrouter.tcl"
+#define GATEWAY_MARKER "GATEWAY=" // FIXME:
 
 #elif (HOST_OS == linux)
 #define DEFAULTROUTER_PATH "/etc/sysconfig/network"
@@ -107,7 +108,7 @@
 
 #define SET_TIMEZONE_SCRIPT INKTOMI_HOME "/rubicon/bin/spi_settimezone.sh"
 #define SET_TIMEZONE_ARGS "1>/usr/tmp/spi_settimezone.log 2>&1"
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 #define TIMEZONE_FILE "/etc/default/init"
 #elif (HOST_OS == linux)
 #define TIMEZONE_FILE "/etc/sysconfig/clock"

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/ClusterCom.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/ClusterCom.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/ClusterCom.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/ClusterCom.cc Fri Jan
22 19:17:30 2010
@@ -2546,9 +2546,14 @@
              (lmgmt->mgmt_shutdown_outstanding ? "true" : "false"));
     mgmt_writeline(req_fd, reply, strlen(reply));
 
-#ifndef _WIN32
+#if !defined(_WIN32)
+#if (HOST_OS == solaris)
+    snprintf(reply, sizeof(reply), "\twatched_process_fd: %d  watched_process_pid: %ld\n",
+             lmgmt->watched_process_fd, lmgmt->watched_process_pid);
+#else
     snprintf(reply, sizeof(reply), "\twatched_process_fd: %d  watched_process_pid: %d\n",
              lmgmt->watched_process_fd, lmgmt->watched_process_pid);
+#endif
     mgmt_writeline(req_fd, reply, strlen(reply));
 #else // We don't have unix domain sockets on NT
     snprintf(reply, sizeof(reply), "\tprocess_server_hpipe: %d  watched_process_pid: %ld\n",

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/VMap.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/VMap.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/VMap.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cluster/VMap.cc Fri Jan 22 19:17:30
2010
@@ -1093,7 +1093,7 @@
 
 #if (HOST_OS == linux)
     res = execl(absolute_vipconf_binary, vip_conf, "up", virt_ip, "/sbin/ifconfig", interface,
sub_id, NULL);
-#elif (HOST_OS == freebsd)
+#elif (HOST_OS == freebsd) || (HOST_OS == solaris)
     res = execl(absolute_vipconf_binary, vip_conf, "up", virt_ip, "/sbin/ifconfig", interface,
sub_id, (char *)0);
 #else
     res = execl(absolute_vipconf_binary, vip_conf, "up", virt_ip, "/usr/sbin/ifconfig", interface,
sub_id, NULL);
@@ -1151,7 +1151,7 @@
 
 #if (HOST_OS == linux)
     res = execl(absolute_vipconf_binary, vip_conf, "down", virt_ip, "/sbin/ifconfig", interface,
sub_id, NULL);
-#elif (HOST_OS == freebsd)
+#elif (HOST_OS == freebsd) || (HOST_OS == solaris)
     res = execl(absolute_vipconf_binary, vip_conf, "down", virt_ip, "/sbin/ifconfig", interface,
sub_id, (char *)0);
 #else
     res = execl(absolute_vipconf_binary, vip_conf, "down", virt_ip, "/usr/sbin/ifconfig",
interface, sub_id, NULL);

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cop/TrafficCop.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cop/TrafficCop.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cop/TrafficCop.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/cop/TrafficCop.cc Fri Jan 22
19:17:30 2010
@@ -1114,7 +1114,11 @@
     if (err == 0) {
       fd = fopen(rni_rpass_lockfile, "w+");
       if (fd > 0) {
+#if (HOST_OS == solaris)
+	fprintf(fd, "%d\n", (int)getpid());
+#else
         fprintf(fd, "%d\n", getpid());
+#endif
         fclose(fd);
       }
 

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/html2/tune/navigation_tree.xmlcpp
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/html2/tune/navigation_tree.xmlcpp?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/html2/tune/navigation_tree.xmlcpp
(original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/html2/tune/navigation_tree.xmlcpp
Fri Jan 22 19:17:30 2010
@@ -170,7 +170,7 @@
     </MENU>
 
     <MENU name="Networking">
-#if (HOST_OS == linux) || (HOST_OS == sunos)
+#if (HOST_OS == linux) || (HOST_OS == solaris)
       <ITEM name="System">
         <LINK refresh="true"
               file_link="/monitor/m_net.ink"
@@ -508,7 +508,7 @@
     </MENU>
 
     <MENU name="Networking">
-#if (HOST_OS == linux) || (HOST_OS == sunos)
+#if (HOST_OS == linux) || (HOST_OS == solaris)
       <ITEM name="System">
         <LINK name="General"
               file_link="/configure/c_net_config.ink"

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.cc Fri Jan 22
19:17:30 2010
@@ -21,7 +21,7 @@
   limitations under the License.
  */
 
-#if (HOST_OS == linux) || (HOST_OS == sunos) || (HOST_OS == freebsd) || (HOST_OS == darwin)
+#if (HOST_OS == linux) || (HOST_OS == solaris) || (HOST_OS == freebsd) || (HOST_OS == darwin)
 
 #include "ConfigAPI.h"
 #include "SysAPI.h"
@@ -64,7 +64,7 @@
 int
 Config_GetHostname(char *hostname, size_t hostname_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetHostname(hostname, hostname_len));
 #else
   return -1;
@@ -75,7 +75,7 @@
 Config_SetHostname(char *hostname)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   char old_hostname[256];
   INKInt val;
   bool rni = false;
@@ -204,7 +204,7 @@
 int
 Config_GetDomain(char *domain, size_t domain_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetDomain(domain, domain_len));
 #else
   return -1;
@@ -248,7 +248,7 @@
 int
 Config_GetDNS_Servers(char *dns, size_t dns_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetDNS_Servers(dns, dns_len));
 #else
   return -1;
@@ -293,7 +293,7 @@
 int
 Config_GetDNS_Server(char *server, size_t server_len, int no)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetDNS_Server(server, server_len, no));
 #else
   return -1;
@@ -333,7 +333,7 @@
 int
 Config_GetNIC_Start(char *interface, char *start, size_t start_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetNIC_Start(interface, start, start_len));
 #else
   return -1;
@@ -343,7 +343,7 @@
 int
 Config_GetNIC_Protocol(char *interface, char *protocol, size_t protocol_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetNIC_Protocol(interface, protocol, protocol_len));
 #else
   return -1;
@@ -373,7 +373,7 @@
 int
 Config_GetNIC_Gateway(char *interface, char *gateway, size_t gateway_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return (Net_GetNIC_Gateway(interface, gateway, gateway_len));
 #else
   return -1;
@@ -538,7 +538,7 @@
                const size_t secondSize)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_GetTime(hour, hourSize, minute, minuteSize, second, secondSize);
 #endif
   return status;
@@ -562,7 +562,7 @@
 Config_GetDate(char *month, const size_t monthSize, char *day, const size_t daySize, char
*year, const size_t yearSize)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_GetDate(month, monthSize, day, daySize, year, yearSize);
 #endif
   return status;
@@ -576,7 +576,7 @@
   if (month == NULL || day == NULL || year == NULL) {
     return -1;
   }
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_SetDate(restart, month, day, year);
 #endif
   return status;
@@ -586,7 +586,7 @@
 Config_SortTimezone(void)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_SortTimezone();
 #endif
   return status;
@@ -596,7 +596,7 @@
 Config_GetTimezone(char *timezone, size_t timezone_len)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_GetTimezone(timezone, timezone_len);
 #endif
   return status;
@@ -620,7 +620,7 @@
 Config_GetNTP_Servers(char *server, size_t server_len)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_GetNTP_Servers(server, server_len);
 #endif
   return status;
@@ -644,7 +644,7 @@
 Config_GetNTP_Server(char *server, size_t server_len, int no)
 {
   int status = -1;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   status = Time_GetNTP_Server(server, server_len, no);
 #endif
   return status;
@@ -719,7 +719,7 @@
 int
 Config_GetNTP_Status(char *status, size_t status_len)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   return Time_GetNTP_Status(status, status_len);
 #else
   return -1;
@@ -995,7 +995,7 @@
   //char ethXNM[24];
   //char ethXGW[24];
   XMLDom netConfigXML;
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   netConfigXML.setNodeName("APPLIANCE_CONFIG");
 
   XMLNode *child2 = new XMLNode;
@@ -1378,7 +1378,7 @@
     }
   } else {
 
-#if (HOST_OS == freebsd) || (HOST_OS == darwin)
+#if (HOST_OS == freebsd) || (HOST_OS == darwin) || (HOST_OS == solaris)
     int res = execl(net_floppy_config,"net_floppy_config","done",(char *)0);
 #else
     int res = execl(net_floppy_config,"net_floppy_config","done",NULL);
@@ -1456,7 +1456,7 @@
       return 1;
     }
   } else {
-#if (HOST_OS == freebsd) || (HOST_OS == darwin)
+#if (HOST_OS == freebsd) || (HOST_OS == darwin) || (HOST_OS == solaris)
     int res = execl(net_floppy_config,"net_floppy_config","do", (char *)0);
 #else
     int res = execl(net_floppy_config,"net_floppy_config","do", NULL);
@@ -1530,4 +1530,4 @@
 
 }
 
-#endif /* (HOST_OS == linux) || (HOST_OS == sunos) || (HOST_OS == freebsd) || (HOST_OS ==
darwin) */
+#endif /* (HOST_OS == linux) || (HOST_OS == solaris) || (HOST_OS == freebsd) || (HOST_OS
== darwin) */

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.h
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.h?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.h (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/ConfigAPI.h Fri Jan 22
19:17:30 2010
@@ -26,7 +26,7 @@
 
 #include "../utils/XmlUtils.h"
 
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 #include "ink_bool.h"
 #endif
 

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/NetConfig.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/NetConfig.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/NetConfig.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/NetConfig.cc Fri Jan 22
19:17:30 2010
@@ -1805,7 +1805,7 @@
 
 #endif
 
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 
 #include <ctype.h>
 #include <stdlib.h>
@@ -1841,6 +1841,7 @@
 #include<sys/types.h>
 
 #include "ink_bool.h"
+#include "ink_string.h"
 
 #define UP_INTERFACE     0
 #define DOWN_INTERFACE   1
@@ -1950,7 +1951,11 @@
   } else {
     int res;
     //printf("!! overwriteFiles mv %s %s\n", source, dest);
+#if (HOST_OS == solaris)
+    res = execl(MV_BINARY, "mv", source, dest, (char*)0);
+#else
     res = execl(MV_BINARY, "mv", source, dest, NULL);
+#endif
     if (res != 0)
       perror(errmsg);
     _exit(res);
@@ -1972,7 +1977,11 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
+#if (HOST_OS == solaris)
+    res = execl(SYMBOLIC_LINK_BINARY, "ln", "-s", original_file, symbolic_link, (char*)0);
+#else
     res = execl(SYMBOLIC_LINK_BINARY, "ln", "-s", original_file, symbolic_link, NULL);
+#endif
     if (res != 0)
       perror(errmsg);
     _exit(res);
@@ -1996,7 +2005,11 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
+#if (HOST_OS == solaris)
+    res = execl(CHMOD_BINARY, "chmod", mode, filename, (char*)0);
+#else
     res = execl(CHMOD_BINARY, "chmod", mode, filename, NULL);
+#endif
     if (res != 0)
       perror(errmsg);
     _exit(res);
@@ -2021,7 +2034,11 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
+#if (HOST_OS == solaris)
+    res = execl(ROUTE_BINARY, "route", "delete", dest, gateway, (char*)0);
+#else
     res = execl(ROUTE_BINARY, "route", "delete", dest, gateway, NULL);
+#endif
     if (res != 0) {
       perror(errmsg);
     }
@@ -2047,7 +2064,11 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
+#if (HOST_OS == solaris)
+    res = execl(ROUTE_BINARY, "route", "delete", dest, gateway, "-ifp", interface, (char*)0);
+#else
     res = execl(ROUTE_BINARY, "route", "delete", dest, gateway, "-ifp", interface, NULL);
+#endif
     if (res != 0) {
       perror(errmsg);
     }
@@ -2070,7 +2091,11 @@
   } else if (pid > 0) {
     waitpid(pid, &status, 0);
   } else {
+#if (HOST_OS == solaris)
+    int res = execl(ROUTE_BINARY, "route", "add", dest, gateway, (char*)0);
+#else
     int res = execl(ROUTE_BINARY, "route", "add", dest, gateway, NULL);
+#endif
     if (res != 0) {
       perror(errmsg);
     }
@@ -2096,7 +2121,11 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
+#if (HOST_OS == solaris)
+    res = execl(ROUTE_BINARY, "route", "add", dest, gateway, "-ifp", interface, (char*)0);
+#else
     res = execl(ROUTE_BINARY, "route", "add", dest, gateway, "-ifp", interface, NULL);
+#endif
     if (res != 0) {
       perror(errmsg);
     }
@@ -2122,7 +2151,11 @@
     waitpid(pid, &status, 0);
   } else {                      // also update the broadcast address field
     int res;
+#if (HOST_OS == solaris)
+    res = execl(IF_CONFIG_BINARY, "ifconfig", interface, ip, "netmask", mask, "broadcast",
"+", (char*)0);
+#else
     res = execl(IF_CONFIG_BINARY, "ifconfig", interface, ip, "netmask", mask, "broadcast",
"+", NULL);
+#endif
     if (res != 0) {
       perror(errmsg);
     }
@@ -2171,7 +2204,7 @@
 {
   const int BUFFLEN = 1024;
   const int PATHLEN = 200;
-  char command[PATHLEN], buffer[BUFFLEN], hostname_path[PATHLEN];
+  char buffer[BUFFLEN], hostname_path[PATHLEN];
   char hosts_path[PATHLEN], hosts_path_new[PATHLEN];
   char hostname[PATHLEN];
   FILE *fd, *fd1;
@@ -2314,7 +2347,7 @@
 
   //need 3 + 1 + 3 + 1+ 3 + 1 + 3 = 15 chars, +1 for the null
   char buff[17];
-  snprintf(buff, sizeof(buf), "%d.%d.%d.%d",
+  snprintf(buff, sizeof(buff), "%d.%d.%d.%d",
            (ip & FIRST_OCTET) >> 24, (ip & SECOND_OCTET) >> 16, (ip &
THIRD_OCTET) >> 8, (ip & FOURTH_OCTET));
   ink_strncpy(ipAddr, buff, ipAddrSize);
   return NETCONFIG_SUCCESS;
@@ -2328,7 +2361,7 @@
 getNetworkNumber(char *ip, char *netmask, char *network_number)
 {
   unsigned int network = (ipDot2int(ip) & ipDot2int(netmask));
-  return ipInt2Dot(network, network_number);
+  return ipInt2Dot(network, network_number, sizeof(network_number));
 }
 
 int
@@ -2370,7 +2403,7 @@
        modify - find line of adding route to specific nic_name
        replace that line
      */
-    snprintf(static_filename_new, sizeof(stat_filename_new), "%s.new", static_filename);
+    snprintf(static_filename_new, sizeof(static_filename_new), "%s.new", static_filename);
     if ((fd1 = fopen(static_filename_new, "w")) == NULL) {
       perror("[net_config] setGatewayForBoot, failed to open new config files");
       return NETCONFIG_FAIL;
@@ -2539,7 +2572,7 @@
     } else if (pid > 0) {
       waitpid(pid, &status, 0);
     } else {
-      int res = execl(IF_CONFIG_BINARY, "ifconfig", nic_name, "up", NULL);
+      int res = execl(IF_CONFIG_BINARY, "ifconfig", nic_name, "up", (char*)0);
       if (res != 0)
         perror(errmsg);
       _exit(res);
@@ -2553,7 +2586,7 @@
       waitpid(pid, &status, 0);
     } else {
       int res;
-      res = execl(IF_CONFIG_BINARY, "ifconfig", nic_name, "plumb", NULL);
+      res = execl(IF_CONFIG_BINARY, "ifconfig", nic_name, "plumb", (char*)0);
       if (res != 0)
         perror(errmsg);
       _exit(res);
@@ -2582,7 +2615,7 @@
         waitpid(pid, &status, 0);
       } else {
         int res;
-        res = execl(STATIC_ROUTE_FILENAME, NULL);
+        res = execl(STATIC_ROUTE_FILENAME, NULL, (char*)0);
         if (res != 0)
           perror(errmsg);
         _exit(res);
@@ -2630,7 +2663,7 @@
   } else if (pid > 0) {
     waitpid(pid, &status, 0);
   } else {
-    int res = execl(IFCONFIG, "ifconfig", nic_name, "auto-dhcp", "drop", NULL);
+    int res = execl(IFCONFIG, "ifconfig", nic_name, "auto-dhcp", "drop", (char*)0);
     if (res != 0) {
       perror(errmsg);
     }
@@ -2785,7 +2818,7 @@
   } else if (pid > 0) {
     waitpid(pid, &status, 0);
   } else {
-    int res = execl(ifconfig_binary, "ifconfig", nic_name, "down", NULL);
+    int res = execl(ifconfig_binary, "ifconfig", nic_name, "down", (char*)0);
     if (res != 0) {
       perror("[net_confg] couldn't bring interface down");
     }
@@ -2857,7 +2890,7 @@
         waitpid(pid, &status, 0);
       } else {
         // printf("MV: %s %s %s \n",mv_binary,mrtg_path_new, mrtg_path); 
-        res = execl(mv_binary, "mv", mrtg_path_new, mrtg_path, NULL);
+        res = execl(mv_binary, "mv", mrtg_path_new, mrtg_path, (char*)0);
         if (res != 0) {
           perror("[net_config] mv of new mrtg file failed ");
         }
@@ -3002,7 +3035,7 @@
   char buffer[BUFFLEN];
   char default_router_path[PATHLEN], default_router_path_new[PATHLEN];
   char cur_gateway_addr[BUFFLEN];
-  FILE *fd, *fd1;
+  FILE *fd;
 
   /* first overwrite the default router file */
   snprintf(default_router_path, sizeof(default_router_path), "%s", DEFAULT_ROUTER_PATH);
@@ -3106,7 +3139,7 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
-    res = execl(mv_binary, "mv", dns_path_new, dns_path, NULL);
+    res = execl(mv_binary, "mv", dns_path_new, dns_path, (char*)0);
     if (res != 0) {
       perror("[net_config] mv of new dns config file failed ");
     }
@@ -3164,7 +3197,7 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
-    res = execl(mv_binary, "mv", domain_path_new, domain_path, NULL);
+    res = execl(mv_binary, "mv", domain_path_new, domain_path, (char*)0);
     if (res != 0) {
       perror("[net_config] mv of new domain config file failed ");
     }
@@ -3220,7 +3253,7 @@
     waitpid(pid, &status, 0);
   } else {
     int res;
-    res = execl(mv_binary, "mv", search_domain_path_new, search_domain_path, NULL);
+    res = execl(mv_binary, "mv", search_domain_path_new, search_domain_path, (char*)0);
     if (res != 0) {
       perror("[net_config] mv of new  search domain config file failed ");
     }

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.cc Fri Jan 22 19:17:30
2010
@@ -634,7 +634,7 @@
 int
 Net_SetNIC_Netmask(char *interface, char *nic_netmask)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   char nic_boot[80], nic_protocol[80], nic_ip[80], nic_gateway[80];
   Net_GetNIC_Start(interface, nic_boot, sizeof(nic_boot));
   Net_GetNIC_Protocol(interface, nic_protocol, sizeof(nic_protocol));
@@ -650,7 +650,7 @@
 int
 Net_SetNIC_Gateway(char *interface, char *nic_gateway)
 {
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   char nic_boot[80], nic_protocol[80], nic_ip[80], nic_netmask[80];
   Net_GetNIC_Start(interface, nic_boot, sizeof(nic_boot));
   Net_GetNIC_Protocol(interface, nic_protocol, sizeof(nic_protocol));
@@ -1845,7 +1845,7 @@
 
 #endif /* (HOST_OS == linux) || (HOST_OS == freebsd) || (HOST_OS == darwin) */
 
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 
 #include "SysAPI.h"
 #include <stdio.h>
@@ -1859,6 +1859,9 @@
 #include <regex.h>
 
 #include <ctype.h>
+
+#include "ink_string.h"
+
 #include "../api2/include/INKMgmtAPI.h"
 
 #include <arpa/inet.h>
@@ -1867,6 +1870,7 @@
 
 #include "ParseRules.h"
 
+
 #define NETCONFIG_HOSTNAME  0
 #define NETCONFIG_GATEWAY   1
 #define NETCONFIG_DOMAIN    2
@@ -1916,7 +1920,7 @@
 static int getTSdirectory(char *ts_path, size_t ts_path_len);
 
 int
-Net_GetHostname(char *hostname)
+Net_GetHostname(char *hostname, size_t hostname_len)
 {
   strcpy(hostname, "");
   return (gethostname(hostname, 256));
@@ -1939,7 +1943,7 @@
     return -1;
   }
 
-  Net_GetHostname(old_hostname);
+  Net_GetHostname(old_hostname,sizeof(old_hostname));
   if (!strlen(old_hostname)) {
     DPRINTF(("Net_SetHostname: failed to get old_hostname\n"));
     return -1;
@@ -1957,13 +1961,13 @@
     nic_status[0] = 0;
     protocol[0] = 0;
     for (int i = 0; i < count; i++) {   //since we are looping - we will get the "last"
available IP - doesn't matter to us
-      Net_GetNetworkInt(i, name);       //we know we have at least one
+      Net_GetNetworkInt(i, name, sizeof(name)); //we know we have at least one
       if (name != NULL) {
-        Net_GetNIC_Status(name, nic_status);
-        Net_GetNIC_Protocol(name, protocol);
+        Net_GetNIC_Status(name, nic_status, sizeof(nic_status));
+        Net_GetNIC_Protocol(name, protocol, sizeof(protocol));
         if ((strcmp("up", nic_status) == 0) && (!found)) {
           //we can use this interface
-          Net_GetNIC_IP(name, ip_addr);
+          Net_GetNIC_IP(name, ip_addr, sizeof(ip_addr));
           found = true;
         }
       }
@@ -2065,14 +2069,14 @@
       }
       if (fgets(buffer, BUFFLEN, fd)) {
         char *p = buffer;
-        while (*p && !isspace(*p) && (p - buffer) < router_len)
+        while (*p && !isspace(*p) && ((size_t)(p - buffer) < router_len))
           *(router++) = *(p++);
         *router = 0;
       }
       fclose(fd);
     } else {                    // found, already in ip format, just need to cpy it
       char *p = buffer;
-      while (*p && !isspace(*p) && (p - buffer) < router_len)
+      while (*p && !isspace(*p) && ((size_t)(p - buffer) < router_len))
         *(router++) = *(p++);
       *router = 0;
     }
@@ -2111,7 +2115,7 @@
 }
 
 int
-Net_GetDomain(char *domain)
+Net_GetDomain(char *domain, size_t domain_len)
 {
   //  domain can be defined using search or domain keyword
   strcpy(domain, "");
@@ -2140,7 +2144,7 @@
 }
 
 int
-Net_GetDNS_Servers(char *dns)
+Net_GetDNS_Servers(char *dns, size_t dns_len)
 {
   char ip[80];
   strcpy(dns, "");
@@ -2211,7 +2215,7 @@
 }
 
 int
-Net_GetNetworkInt(int int_num, char *interface)
+Net_GetNetworkInt(int int_num, char *interface, size_t interface_len)//FIXME: use interface_len
 {
   strcpy(interface, "");
 
@@ -2264,7 +2268,7 @@
 }
 
 int
-Net_GetNIC_Status(char *interface, char *status)
+Net_GetNIC_Status(char *interface, char *status, size_t status_len) // FIXME: use status_line
 {
   const int BUFFLEN = 80;
   char buffer[BUFFLEN];
@@ -2286,7 +2290,7 @@
 }
 
 int
-Net_GetNIC_Start(char *interface, char *start)
+Net_GetNIC_Start(char *interface, char *start, size_t start_len)
 {
   const int PATHLEN = 200;
   char hostnamefile[PATHLEN];
@@ -2302,7 +2306,7 @@
 }
 
 int
-Net_GetNIC_Protocol(char *interface, char *protocol)
+Net_GetNIC_Protocol(char *interface, char *protocol, size_t protocol_len)
 {
   const int PATHLEN = 200;
   char dhcp_filename[PATHLEN];
@@ -2399,7 +2403,7 @@
 }
 
 int
-Net_GetNIC_IP(char *interface, char *ip)
+Net_GetNIC_IP(char *interface, char *ip, size_t nic_ip_len)//FIXME: use nic_ip_len
 {
   strcpy(ip, "");               // bug 50628, initialize for null value
   int status = parseIfconfig(interface, "inet ", ip);
@@ -2426,7 +2430,7 @@
     while (!feof(fd) && isLineCommented(hostname))      // skip # and blank
       fgets(hostname, PATHLEN, fd);
 
-    if (!hostname) {
+    if (hostname[0] == '\0') {
       DPRINTF(("[NET_GETNIC_IP] failed to get hostname"));
       return -1;
     }
@@ -2469,7 +2473,7 @@
     FILE *fd;
 
 
-    status = Net_GetNIC_IP(interface, ip_addr);
+    status = Net_GetNIC_IP(interface, ip_addr, sizeof(ip_addr));
     if (status != 0) {
       DPRINTF(("[NET_GETNIC_NETMASK] failed to obtain ip address"));
       return -1;
@@ -2538,7 +2542,7 @@
 }
 
 int
-Net_GetNIC_Gateway(char *interface, char *gateway)
+Net_GetNIC_Gateway(char *interface, char *gateway, size_t gateway_len)
 {
   // command is netstat -rn | grep <interface name> | grep G
   // the 2nd column is the Gateway
@@ -2577,7 +2581,7 @@
     return status;
   }
 
-  Net_GetNIC_IP(interface, ip);
+  Net_GetNIC_IP(interface, ip, sizeof(ip));
 
   return status;
 }
@@ -2587,10 +2591,10 @@
 {
   char nic_protocol[80], nic_ip[80], nic_netmask[80], nic_gateway[80];
 
-  Net_GetNIC_Protocol(interface, nic_protocol);
-  Net_GetNIC_IP(interface, nic_ip);
-  Net_GetNIC_Netmask(interface, nic_netmask);
-  Net_GetNIC_Gateway(interface, nic_gateway);
+  Net_GetNIC_Protocol(interface, nic_protocol,sizeof(nic_protocol));
+  Net_GetNIC_IP(interface, nic_ip, sizeof(nic_ip));
+  Net_GetNIC_Netmask(interface, nic_netmask, sizeof(nic_netmask));
+  Net_GetNIC_Gateway(interface, nic_gateway, sizeof(nic_gateway));
 
   return (Net_SetNIC_Up(interface, onboot, nic_protocol, nic_ip, nic_netmask, nic_gateway));
 }
@@ -2600,10 +2604,10 @@
 {
   char nic_boot[80], nic_ip[80], nic_netmask[80], nic_gateway[80];
 #if (HOST_OS != freebsd) && (HOST_OS != darwin)
-  Net_GetNIC_Start(interface, nic_boot);
-  Net_GetNIC_IP(interface, nic_ip);
-  Net_GetNIC_Netmask(interface, nic_netmask);
-  Net_GetNIC_Gateway(interface, nic_gateway);
+  Net_GetNIC_Start(interface, nic_boot, sizeof(nic_boot));
+  Net_GetNIC_IP(interface, nic_ip, sizeof(nic_ip));
+  Net_GetNIC_Netmask(interface, nic_netmask, sizeof(nic_netmask));
+  Net_GetNIC_Gateway(interface, nic_gateway, sizeof(nic_gateway));
 
   return (Net_SetNIC_Up(interface, nic_boot, nic_protocol, nic_ip, nic_netmask, nic_gateway));
 #else
@@ -2615,12 +2619,12 @@
 Net_SetNIC_IP(char *interface, char *nic_ip)
 {
   //int status;
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   char nic_boot[80], nic_protocol[80], nic_netmask[80], nic_gateway[80], old_ip[80];
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
-  Net_GetNIC_IP(interface, old_ip);
+  Net_GetNIC_IP(interface, old_ip, sizeof(old_ip));
   Net_GetNIC_Start(interface, nic_boot);
   Net_GetNIC_Protocol(interface, nic_protocol);
-  Net_GetNIC_Netmask(interface, nic_netmask);
+  Net_GetNIC_Netmask(interface, nic_netmask, sizeof(nic_netmask));
   Net_GetNIC_Gateway(interface, nic_gateway);
 
   return (Net_SetNIC_Up(interface, nic_boot, nic_protocol, nic_ip, nic_netmask, nic_gateway));
@@ -2632,11 +2636,11 @@
 int
 Net_SetNIC_Netmask(char *interface, char *nic_netmask)
 {
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   char nic_boot[80], nic_protocol[80], nic_ip[80], nic_gateway[80];
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
   Net_GetNIC_Start(interface, nic_boot);
   Net_GetNIC_Protocol(interface, nic_protocol);
-  Net_GetNIC_IP(interface, nic_ip);
+  Net_GetNIC_IP(interface, nic_ip, sizeof(nic_ip));
   Net_GetNIC_Gateway(interface, nic_gateway);
 
   return (Net_SetNIC_Up(interface, nic_boot, nic_protocol, nic_ip, nic_netmask, nic_gateway));
@@ -2648,12 +2652,12 @@
 int
 Net_SetNIC_Gateway(char *interface, char *nic_gateway)
 {
+#if (HOST_OS != freebsd) && (HOST_OS != darwin) && (HOST_OS != solaris)
   char nic_boot[80], nic_protocol[80], nic_ip[80], nic_netmask[80];
-#if (HOST_OS != freebsd) && (HOST_OS != darwin)
   Net_GetNIC_Start(interface, nic_boot);
   Net_GetNIC_Protocol(interface, nic_protocol);
-  Net_GetNIC_IP(interface, nic_ip);
-  Net_GetNIC_Netmask(interface, nic_netmask);
+  Net_GetNIC_IP(interface, nic_ip, sizeof(nic_ip));
+  Net_GetNIC_Netmask(interface, nic_netmask, sizeof(nic_netmask));
 
   //   DPRINTF(("Net_SetNIC_Gateway:: interface %s onboot %s protocol %s ip %s netmask %s
gateway %s\n", interface, nic_boot, nic_protocol, nic_ip, nic_netmask, nic_gateway));
 
@@ -2685,9 +2689,9 @@
   const int BUFFLEN = 200;
   char old_ip[BUFFLEN], old_mask[BUFFLEN], old_gateway[BUFFLEN], default_gateway[BUFFLEN];
 
-  Net_GetNIC_IP(interface, old_ip);
-  Net_GetNIC_Netmask(interface, old_mask);
-  Net_GetNIC_Gateway(interface, old_gateway);
+  Net_GetNIC_IP(interface, old_ip, sizeof(old_ip));
+  Net_GetNIC_Netmask(interface, old_mask, sizeof(old_mask));
+  Net_GetNIC_Gateway(interface, old_gateway, sizeof(old_gateway));
   Net_GetDefaultRouter(default_gateway, sizeof(default_gateway));
 
   if (strcmp(protocol, "static") == 0)
@@ -2722,7 +2726,7 @@
   }
   int count = Net_GetNetworkIntCount();
   for (int i = 0; i < count; i++) {
-    Net_GetNetworkInt(i, name);
+    Net_GetNetworkInt(i, name, sizeof(name));
     if (strcmp(name, interface) == 0)
       return 1;
   }
@@ -2808,7 +2812,7 @@
 {
   char addr[80];
   char octet1[16], octet2[16], octet3[16], octet4[16];
-  int byte1, byte2, byte3, byte4;
+  int byte1 = 0, byte2 = 0, byte3 = 0, byte4 = 0;
   char junk[256];
 
   if (ip_addr == NULL) {
@@ -3041,8 +3045,8 @@
   FILE *fp;
   char *env_path;
 
-  if ((env_path = getenv("ROOT")) || (env_path = getenv("INST_ROOT"))) {
-    ink_strcnpy(ts_path, env_path, ts_path_len);
+  if ((env_path = getenv("TS_ROOT"))) {
+    ink_strncpy(ts_path, env_path, ts_path_len);
     return 0;
   }
   if ((fp = fopen("/etc/traffic_server", "r")) == NULL) {
@@ -3136,7 +3140,7 @@
   FILE *fp;
   const char *ntpconf = "/etc/ntp.conf";
   char buffer[1024];
-  char *option, *server_name;
+  char *option, *server_name = NULL;
 
   fp = fopen(ntpconf, "r");
   if (fp == NULL) {
@@ -3338,4 +3342,4 @@
   return 0;
 }
 
-#endif /* (HOST_OS == sunos) */
+#endif /* (HOST_OS == solaris) */

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.h
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.h?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.h (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/SysAPI.h Fri Jan 22 19:17:30
2010
@@ -24,7 +24,7 @@
 #ifndef _SYS_API_H
 #define _SYS_API_H
 
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 #include "ink_bool.h"
 #endif
 

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/VIPConfig.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/VIPConfig.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/VIPConfig.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/tools/VIPConfig.cc Fri Jan 22
19:17:30 2010
@@ -222,7 +222,7 @@
     } else if (pid > 0) {
       wait(&status);
     } else {                    /* Exec the up */
-#if (HOST_OS == freebsd)
+#if (HOST_OS == freebsd) || (HOST_OS == solaris)
       int res = execl(binary, "ifconfig", interface, "up", (char *)0);
 #else
       int res = execl(binary, "ifconfig", interface, "up", NULL);
@@ -239,7 +239,7 @@
 
 // "netmask +" is broken on Solaris 2.6 & 2.7,
 // it never actually checks against /etc/netmasks.
-#if (HOST_OS == freebsd)
+#if (HOST_OS == freebsd) || (HOST_OS == solaris)
     int res = execl(binary, "ifconfig", interface, vip, "netmask", "+", "broadcast", "+",
"metric", "1", (char *)0);
 #else
     int res = execl(binary, "ifconfig", interface, vip, "netmask", "+", "broadcast", "+",
"metric", "1", NULL);
@@ -314,7 +314,7 @@
     } else if (pid > 0) {
       wait(&status);
     } else {                    /* Exec the remove */
-#if (HOST_OS == freebsd)
+#if (HOST_OS == freebsd) || (HOST_OS == solaris)
       int res = execl(binary, "ifconfig", interface, "inet", "0.0.0.0", (char *)0);
 #else
       int res = execl(binary, "ifconfig", interface, "inet", "0.0.0.0", NULL);
@@ -330,7 +330,7 @@
   } else {                      /* Exec the down */
     int res = 0;
     // don't down the inter on linux, it'll shutdown the driver
-#if (HOST_OS == freebsd)
+#if (HOST_OS == freebsd) || (HOST_OS == solaris)
     res = execl(binary, "ifconfig", interface, "down", (char *)0);
 #else
     res = execl(binary, "ifconfig", interface, "down", NULL);

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/utils/MgmtUtils.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/utils/MgmtUtils.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/utils/MgmtUtils.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/utils/MgmtUtils.cc Fri Jan 22
19:17:30 2010
@@ -580,7 +580,7 @@
     mgmt_log(stderr, "[getAddrForIntr] Unable to obtain MTU for " "interface '%s'", ifr->ifr_name);
     return 0;
   } else
-#if (HOST_OS == sunos) || (HOST_OS == hpux)
+#if (HOST_OS == solaris) || (HOST_OS == hpux)
     return ifr->ifr_metric;
 #else
     return ifr->ifr_mtu;

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebCompatibility.h
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebCompatibility.h?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebCompatibility.h (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebCompatibility.h Fri Jan
22 19:17:30 2010
@@ -61,7 +61,7 @@
 //                                  struct hostent *result, char *buffer, int buflen, int
*h_errnop);
 #endif
 
-#if (HOST_OS == sunos)
+#if (HOST_OS == solaris)
 extern "C"
 {
   struct hostent *gethostbyaddr_r(const char *addr,

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttp.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttp.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttp.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttp.cc Fri Jan 22 19:17:30
2010
@@ -3932,7 +3932,7 @@
 //  if (recs_out_of_date)
 //    goto Lout_of_date;
 
-#if (HOST_OS == linux) || (HOST_OS == sunos)
+#if (HOST_OS == linux) || (HOST_OS == solaris)
 
   InkHashTableIteratorState htis;
   InkHashTableEntry *hte;

Modified: incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttpRender.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttpRender.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttpRender.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/mgmt2/web2/WebHttpRender.cc Fri Jan
22 19:17:30 2010
@@ -3533,7 +3533,7 @@
 handle_network(WebHttpContext * whc, char *tag, char *arg)
 {
   int err = WEB_HTTP_ERR_OKAY;
-#if (HOST_OS == linux) || (HOST_OS == sunos)
+#if (HOST_OS == linux) || (HOST_OS == solaris)
   char value[1024];
   char *value_safe, *old_value, *dummy;
   char *pos;
@@ -3978,7 +3978,7 @@
   int file_size;
   char *doc_root_file;
   ink_debug_assert(file != NULL);
-#if (HOST_OS == linux)
+#if (HOST_OS == linux) || (HOST_OS == solaris)
 //Bug 49922, for those .ink files which may meet the root-only system files,  
 //upgrade the uid to root.
   int old_euid;
@@ -4011,7 +4011,7 @@
 
 Ldone:
 
-#if (HOST_OS == linux) || (HOST_OS == sunos)
+#if (HOST_OS == linux) || (HOST_OS == solaris)
   if (change_uid) {
     Config_User_Inktomi(old_euid);
   }

Modified: incubator/trafficserver/traffic/branches/dev/proxy/signals.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/branches/dev/proxy/signals.cc?rev=902234&r1=902233&r2=902234&view=diff
==============================================================================
--- incubator/trafficserver/traffic/branches/dev/proxy/signals.cc (original)
+++ incubator/trafficserver/traffic/branches/dev/proxy/signals.cc Fri Jan 22 19:17:30 2010
@@ -297,8 +297,13 @@
   //
   if (t) {
     if (t->si_code <= 0) {
+#if (HOST_OS == solaris)
+      snprintf(sig_msg, sizeof(sig_msg), "NOTE: Traffic Server received User Sig %d from
pid: %d uid: %d\n",
+               sig, (int)t->si_pid, t->si_uid);
+#else
       snprintf(sig_msg, sizeof(sig_msg), "NOTE: Traffic Server received User Sig %d from
pid: %d uid: %d\n",
                sig, t->si_pid, t->si_uid);
+#endif
     } else {
       snprintf(sig_msg, sizeof(sig_msg), "NOTE: Traffic Server received Kernel Sig %d, Reason:
%d\n", sig, t->si_code);
     }



Mime
View raw message