PERFORCE change 170405 for review

View: New views
1 Messages — Rating Filter:   Alert me  

PERFORCE change 170405 for review

by Jonathan Anderson-7 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

http://p4web.freebsd.org/chv.cgi?CH=170405

Change 170405 by jona@jona-capsicum-kent on 2009/11/09 16:47:10

        Removed the multiple definitions which snuck in here

Affected files ...

.. //depot/projects/trustedbsd/capabilities/src/lib/csu/amd64/crt1.c#4 edit
.. //depot/projects/trustedbsd/capabilities/src/lib/csu/common/crtbrand.c#5 edit
.. //depot/projects/trustedbsd/capabilities/src/lib/csu/i386-elf/crt1.c#4 edit

Differences ...

==== //depot/projects/trustedbsd/capabilities/src/lib/csu/amd64/crt1.c#4 (text+ko) ====

@@ -134,42 +134,4 @@
  exit( cap_main(argc, argv, env) );
 }
 
-
-/* The Capsicum entry function. */
-void
-_capstart(char **ap, void (*cleanup)(void))
-{
- int argc;
- char **argv;
- char **env;
- const char *s;
-
- argc = *(long *)(void *)ap;
- argv = ap + 1;
- env = ap + 2 + argc;
- environ = env;
- if (argc > 0 && argv[0] != NULL) {
- __progname = argv[0];
- for (s = __progname; *s != '\0'; s++)
- if (*s == '/')
- __progname = s + 1;
- }
-
- if (&_DYNAMIC != NULL)
- atexit(cleanup);
- else
- _init_tls();
-
-#ifdef GCRT
- atexit(_mcleanup);
-#endif
- atexit(_fini);
-#ifdef GCRT
-/* monstartup(&eprol, &etext);
-__asm__("eprol:");*/        /* XXX: does this interfere with profiling? */
-#endif
- _init();
- exit( cap_main(argc, argv, env) );
-}
-
 __asm__(".ident\t\"$FreeBSD: src/lib/csu/amd64/crt1.c,v 1.15 2005/10/07 22:13:17 bde Exp $\"");

==== //depot/projects/trustedbsd/capabilities/src/lib/csu/common/crtbrand.c#5 (text+ko) ====

@@ -62,17 +62,3 @@
  write(2, warning, sizeof(warning));
 }
 
-
-int cap_main(int argc, char **argv, char **env)
-{
- const char warning[] =
- "ERROR: attempting to run a regular binary in capability mode."
- "\n\n"
- "If you wish to run a binary in a sandbox, you must provide a "
- "cap_main() function which takes the same arguments as main()."
- "\n";
-
- write(2, warning, sizeof(warning));
- return 1;
-}
-

==== //depot/projects/trustedbsd/capabilities/src/lib/csu/i386-elf/crt1.c#4 (text+ko) ====

@@ -155,49 +155,4 @@
  exit( cap_main(argc, argv, env) );
 }
 
-
-
-
-/* The Capsicum entry function. */
-void
-_capstart(char *ap, ...)
-{
- fptr cleanup;
- int argc;
- char **argv;
- char **env;
- const char *s;
-
-#ifdef __GNUC__
- __asm__("and $0xfffffff0,%esp");
-#endif
- cleanup = get_rtld_cleanup();
- argv = ≈
- argc = *(long *)(void *)(argv - 1);
- env = argv + argc + 1;
- environ = env;
- if (argc > 0 && argv[0] != NULL) {
- __progname = argv[0];
- for (s = __progname; *s != '\0'; s++)
- if (*s == '/')
- __progname = s + 1;
- }
-
- if (&_DYNAMIC != NULL)
- atexit(cleanup);
- else
- _init_tls();
-
-#ifdef GCRT
- atexit(_mcleanup);
-#endif
- atexit(_fini);
-#ifdef GCRT
-/* monstartup(&eprol, &etext);
-__asm__("eprol:");*/        /* XXX: does this interfere with profiling? */
-#endif
- _init();
- exit( cap_main(argc, argv, env) );
-}
-
 __asm__(".ident\t\"$FreeBSD: src/lib/csu/i386-elf/crt1.c,v 1.15 2005/10/07 22:13:17 bde Exp $\"");
_______________________________________________
p4-projects@... mailing list
http://lists.freebsd.org/mailman/listinfo/p4-projects
To unsubscribe, send any mail to "p4-projects-unsubscribe@..."