[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: mp4h: Strange? segfault problem
From: |
Samuel Thibault |
Subject: |
Re: mp4h: Strange? segfault problem |
Date: |
Wed, 28 Dec 2011 10:33:12 +0100 |
User-agent: |
Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30) |
Svante Signell, le Wed 28 Dec 2011 10:17:24 +0100, a écrit :
> On GNU/Linux shortening the resolvedname vector from PATH_MAX to 64
> results in a stack corruption. This is not nice, but since that vector
> is allocated on the stack, maybe it is more acceptable than an
> environment corruption.
Well, this is not surprising to get crashes when cheating with PATH_MAX:
the kernel still thinks PATH_MAX is 4096, and thus thinks that the
buffer is actually 4096 bytes long, and thus happily overwrites whatever
is after it if userland doesn't make it so.
Samuel