Skip to contentSkip to conversation

dosemu 1.2.1.0 hanging during startup

DISCUSSION Stas Sergeev 2 participants 2 messages Apr 2, 2004 – Apr 3, 2004

lore
Share & tools
lore
#0 lore raw

Hello.

Quoted 1 line · James B. Hiller

So the presence of the debugger is affecting the hang.

You can start dosdebug *after* dosemu is locked up, not before (not with -H1).

Quoted 3 lines

This is making
me think "pointer error" somewhere, but I couldn't even begin to guess how to proceed. Any suggestions?

You can use the memory debugger njamd. It can work with dosemu, but only if you change every instance of sigaction() call to dosemu_sigaction() call in emu.h and recompile the dosemu.
Then you can set LD_PRELOAD to libnjamd.so, run dosemu, and if it segfaults, then there is probably a memory corruption and you'll need to create a stack trace with gdb at that point.
If this is the case, please open a bug report on BTS for it.

#1 lore raw

Hi.

Quoted 3 lines
Quoted 1 line

So the presence of the debugger is affecting the hang.

You can start dosdebug *after* dosemu is locked up, not before (not with -H1).

My apologies. I think my use of the word "hang" is imprecise, and other descriptions I gave got lost in the edits. The CPU is running forever, so it's not really a hang, but an infinite loop. When I do what you said above, I get:

DOSEMU Debugger V0.6 connected
- type ? to get help on commands -
Reading map file nm /usr/local/bin/dosemu.bin | grep -v '\(compiled\)\|\(\.o$\)\|\( a \)' | sort 3985 symbol(s) processed
highest address 08455898(_end)
system state: running

AX=0101  BX=442b  CX=000a  DX=1c77  SI=40f1  DI=40e6  SP=11d2  BP=0024
DS=0000  ES=8785  FS=0000  GS=0000  FL=02d7

CS:IP=0070:0447 SS:SP=8785:11d2

0070:0447 CA0200 retf 0002
g
already in running state

So I guess I'm going to need to instrument the source code with some printf's in good places to identify where it's looping forever. I was hoping from the output that I had given that someone could give me some idea where to start, since I'm not at all familiar with the source structure.

Also, as I made my original post, I was hoping that, since this behavior is happening before dosemu finishes even getting started, and since my setup for it is trivial, that someone else might be running into the same issue, or that it might in some way be familiar to someone, so that I wouldn't have to spend forever knocking it down.

Guess not.

Quoted 3 lines
Quoted 1 line

how to proceed. Any suggestions?

You can use the memory debugger njamd. It can work with dosemu, but only if

[snip]

Quoted 4 lines

and you'll need to create a stack trace with gdb at that point.
If this is the case, please open a bug report on BTS for it.

If I can get that far with it, yes, certainly.

thx,
jbh