components/openscap/patches/isainfo.c.patch
author Michael Nestler <Michael.Nestler@Oracle.COM>
Wed, 15 Oct 2014 09:26:27 -0700
branchs11u2-sru
changeset 3398 344bcc9ffb11
parent 2821 8add1494802c
permissions -rw-r--r--
19789649 rsyslog complete documentation is missing
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2821
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     1
--- openscap-0.9.7/src/OVAL/probes/unix/solaris/isainfo.c.~1~	2013-04-23 06:21:51.478000001 -0700
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     2
+++ openscap-0.9.7/src/OVAL/probes/unix/solaris/isainfo.c	2013-09-10 11:06:13.488839049 -0700
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     3
@@ -47,6 +47,7 @@
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     4
 #include <arpa/inet.h>
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     5
 #include <regex.h>
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     6
 #include <sys/systeminfo.h>
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     7
+#include "../../../../common/debug_priv.h"
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     8
 
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
     9
 /* man sysinfo (2) recommends using 257 for this size */
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    10
 #define MAX_STR_RESULT 257
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    11
@@ -92,8 +93,12 @@
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    12
 	if (sysinfo(SI_ARCHITECTURE_K, result.kernel_isa, MAX_STR_RESULT) == -1) {
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    13
 		return err;
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    14
 	}
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    15
-
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    16
+#if defined(__SVR4) && defined(__sun)
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    17
+	if ((sysinfo(SI_ARCHITECTURE_32, result.application_isa, MAX_STR_RESULT) == -1) &&
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    18
+	   (sysinfo(SI_ARCHITECTURE_64, result.application_isa, MAX_STR_RESULT) == -1)) {
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    19
+#else
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    20
 	if (sysinfo(SI_ARCHITECTURE_NATIVE, result.application_isa, MAX_STR_RESULT) == -1) {
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    21
+#endif
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    22
 		return err;
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    23
 	}
8add1494802c 17270625 textfilecontent54 probe fails to match patterns in file XScreensaver
Jacob Varughese <jacob.varughese@oracle.com>
parents:
diff changeset
    24