* elf64-ppc.c (dec_dynrel_count): Don't error when elf_gc_sweep_symbol
[external/binutils.git] / sim / testsuite / sim / cris / c / mprotect1.c
index ef249ec..8dae50b 100644 (file)
@@ -2,15 +2,18 @@
 #notarget: cris*-*-elf
 #xerror:
 #output: Unimplemented mprotect call (0x0, 0x2001, 0x4)\n
-#output: program stopped with signal 4.\n
+#output: program stopped with signal 4 (*).\n
  */
 #include <stdlib.h>
 #include <stdio.h>
 #include <sys/mman.h>
+#include <errno.h>
 
 int main (int argc, char *argv[])
 {
-  mprotect (0, 8193, PROT_EXEC);
+  int err = mprotect (0, 8193, PROT_EXEC);
+  if (err == -1 && errno == ENOSYS)
+    printf ("ENOSYS\n");
   printf ("xyzzy\n");
   exit (0);
 }