No Shell Prompt In Terminal
|Reported by:||bonefish||Owned by:||axeld|
|Has a Patch:||no||Platform:||All|
Sometimes a Terminal comes up without a shell prompt. I've analyzed the situation and apparently the shell had received a SIGWINCH while it was in the allocator (free()) and held the lock. The signal handler it had installed earlier was invoked and this handler called malloc(), thus causing a deadlock when it tried to re-lock.
I'm not quite sure, who's to blame. I suppose the memory allocator can't really do anything about it -- temporarily blocking signals would be a little too expensive. So it would be either the Terminal, which maybe shouldn't cause a SIGWINCH that early, or the shell, which should be more careful about what signal handlers it has installed and what signals unblocked while allocating/freeing memory. I tend towards the latter, but also wonder why I've never seen this problem on other platforms before.