lkml.org 
[lkml]   [2003]   [Mar]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectclone or ptrace bug?
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Using strace on an MT application I see strange output from restarted
clone() calls. Something like this:

[pid 17862]
clone(CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID|CLONE_DETACHED
-> child_stack=0x41147ab0,
flags=CLONE_FILES|CLONE_IDLETASK|CLONE_PTRACE|CLONE_VFORK|CLONE_PARENT|CLONE_THREAD|CLONE_NEWNS|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID|CLONE_DETACHED|CLONE_UNTRACED|CLONE_CHILD_SETTID|0xbe0000f8,
[17884], {entry_number:6, base_addr:0x41147d40, limit:1048575,
seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1,
seg_not_present:0, useable:1}, 0x41147d88) = 17884


This is the output of a hacked version of strace. The part before the
"->" is printed when the syscall enters the kernel. Normally nothing
gets printed at that time.

The problem is that the flags word is different after the syscall. This
/might/ not cause any real problems in this case but what happens if the
syscall gets restarted?

In any case, the parameters should be modified.

This is with the 2.5 BK kernel from yesterady or the day before with gcc
3.2.2-5.

- --
- --------------. ,-. 444 Castro Street
Ulrich Drepper \ ,-----------------' \ Mountain View, CA 94041 USA
Red Hat `--' drepper at redhat.com `---------------------------
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE+f4UF2ijCOnn/RHQRAuYzAKCpVPRV8rG+NetG3REIC9OrIZLBwQCgsNt6
S5xj6kjpbKCwZl6WVuadcrA=
=tvm4
-----END PGP SIGNATURE-----

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:34    [W:0.110 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site