diff options
1 files changed, 4 insertions, 2 deletions
diff --git a/hdaps-tux.c b/hdaps-tux.c
index 1856040..28dac2e 100644
--- a/hdaps-tux.c
+++ b/hdaps-tux.c
@@ -129,8 +129,10 @@ int main(int argc, char *argv[])
dprintf("xdiff/ydiff: %d/%d\n", xdiff, ydiff);
- tuxX += xdiff * vel;
- tuxY += ydiff * vel;
+ if (abs(xdiff) > 2)
+ tuxX += xdiff * vel;
+ if (abs(ydiff) > 2)
+ tuxY += ydiff * vel;
timeout = TIMEOUT_VAL;
ing flag in the shared databases, so that the clients are notified when nscd is restarted. Now, when nscd uses a non-persistent database, clients that have it mapped keep thinking the database is being updated by nscd, when in fact nscd has created a new (anonymous) one (for non-persistent databases it uses an unlinked file as backend). The original proposal for the CLONE_CHILD_CLEARTID change claimed ( : The NPTL library uses the CLONE_CHILD_CLEARTID flag on clone() syscalls : on behalf of pthread_create() library calls. This feature is used to : request that the kernel clear the thread-id in user space (at an address : provided in the syscall) when the thread disassociates itself from the : address space, which is done in mm_release(). : : Unfortunately, when a multi-threaded process incurs a core dump (such as : from a SIGSEGV), the core-dumping thread sends SIGKILL signals to all of : the other threads, which then proceed to clear their user-space tids : before synchronizing in exit_mm() with the start of core dumping. This : misrepresents the state of process's address space at the time of the : SIGSEGV and makes it more difficult for someone to debug NPTL and glibc : problems (misleading him/her to conclude that the threads had gone away : before the fault). : : The fix below is to simply avoid the CLONE_CHILD_CLEARTID action if a : core dump has been initiated. The resulting patch from Roland ( seems to have a larger scope than the original patch asked for. It seems that limitting the scope of the check to core dumping should work for SIGSEGV issue describe above. [Changelog partly based on Andreas' description] Fixes: fec1d0115240 ("[PATCH] Disable CLONE_CHILD_CLEARTID for abnormal exit") Link: Signed-off-by: Michal Hocko <> Tested-by: William Preston <> Acked-by: Oleg Nesterov <> Cc: Roland McGrath <> Cc: Andreas Schwab <> Signed-off-by: Andrew Morton <> Signed-off-by: Linus Torvalds <>
Diffstat (limited to 'kernel/fork.c')
1 files changed, 4 insertions, 6 deletions
diff --git a/kernel/fork.c b/kernel/fork.c