From: Mike F. <va...@us...> - 2009-11-03 20:07:44
|
Update of /cvsroot/ltp/ltp/include In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv22635/include Modified Files: test.h Log Message: define and use common clone helpers From: Serge E. Hallyn <se...@us...> Define ltp_clone() and related helpers in libltp, and convert all existing clone usages to them. This way we no longer have arch-specific cruft cluttering up random source files all over the place. Index: test.h =================================================================== RCS file: /cvsroot/ltp/ltp/include/test.h,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** test.h 27 Sep 2009 17:46:05 -0000 1.23 --- test.h 3 Nov 2009 20:07:35 -0000 1.24 *************** *** 246,249 **** --- 246,260 ---- int self_exec(char *argv0, char *fmt, ...); + /* + * Functions from lib/cloner.c + */ + int ltp_clone(unsigned long clone_flags, int (*fn)(void *arg), void *arg, + size_t stack_size, void *stack); + int ltp_clone_malloc(unsigned long clone_flags, int (*fn)(void *arg), + void *arg, size_t stacksize); + int ltp_clone_quick(unsigned long clone_flags, int (*fn)(void *arg), + void *arg); + #define clone(...) use_the_ltp_clone_functions,do_not_use_clone + #ifdef TST_USE_COMPAT16_SYSCALL #define TCID_BIT_SUFFIX "_16" |