Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Weird error when trying to run NTVDM.EXE for the first time #17

Closed
AEAEAEAE4343 opened this issue Dec 23, 2017 · 16 comments
Closed

Weird error when trying to run NTVDM.EXE for the first time #17

AEAEAEAE4343 opened this issue Dec 23, 2017 · 16 comments

Comments

@AEAEAEAE4343
Copy link

Hi, I'm getting this weird error when trying to load ntvdm.exe:
ntvdm
Both buttons do nothing.
BTW I am running Windows 10 Insider Preview 1709(Build 17017)

@leecher1337
Copy link
Owner

Any chance that you tried to launch ntvdm.exe directly?
ntvdm cannot be run directly, obviousy. You need ldntvdm.dll to inject into the operating system loader and start a DOS application so that the OS loader can setup environment correctly.

@AEAEAEAE4343
Copy link
Author

I did run ntvdm directly. BUT when trying to start a dos app(command.com for example) It says 16 bit is not supported? Have i installed it incorrectly?

@leecher1337
Copy link
Owner

Please update your ldntvdm.dll for System32 and SysWOW64 with the newest versions from this repository, there is a change in Fall Creators Update that broke the loader. And then verify with process explorer, that the .dlls get loaded into every process on your system. If this isn't the case, check if AppInit_DLLs is working correctly.
Did you install it with the install.bat and did it run through smoothy?

@AEAEAEAE4343
Copy link
Author

AEAEAEAE4343 commented Dec 27, 2017

Yes install.bat ran smoothly. But do i seriously have to recompile everything with the new source code? I couldn't even compile it myself. The batch files keeped throwing errors on me. Then i found a compiled version on #7.
EDIT: Found the patched lntvdm.dll's. Gonna try them out now

@AEAEAEAE4343
Copy link
Author

Wow it worked. Thanks!

@AEAEAEAE4343
Copy link
Author

AEAEAEAE4343 commented Dec 27, 2017

I get an error when trying to run edit (BTW Sorry for dutch command prompt)

When trying to run edit from command.com i just see this:

@AEAEAEAE4343 AEAEAEAE4343 reopened this Dec 27, 2017
@leecher1337
Copy link
Owner

Weird... looks like edit.com is displayed instead of executed.. Can you check if there are some errors displayed in DbgView console?
Also, does ntvdm.exe execute fine? Do other DOS-programs work fine or are they also doing weird things? What does it do if you execute QBASIC.EXE?

@AEAEAEAE4343
Copy link
Author

AEAEAEAE4343 commented Dec 27, 2017

Can you check if there are some errors displayed in DbgView console?

How do I do this?

What does it do if you execute QBASIC.EXE?

Plain black screen, nothing happens

EDIT: Figured it out, here are the results:
WITH CMD.EXE
3
WITH COMMAND.COM
4
I think it's missing the msdos font.

@emendelson
Copy link

I get a variety of errors when trying to run EDIT.COM:

When I start it from WINDOWS\System32, it produces a blank window.

When I first ran the WordPerfect ED.EXE, and then tried to run EDIT, it produced the same weird screen showing the content of the file (with the QBASIC string, etc.)

The errors don't seem predictable.

@AEAEAEAE4343
Copy link
Author

OK, running it in different locations does make a change, BUT, running it in the same place a couple of times gives the same output. All of the outputs that are in this post are all from C:\Users\anis1(My profile folder) So it is kinda predictable

@leecher1337
Copy link
Owner

leecher1337 commented Dec 27, 2017

Hmn, this is weird... I tried to reproduce the problem, it always started up fine when launching from explorer.exe, but as soon as I launch it from a 32bit process, it starts to act strange. Can you confirm?

Edit: Seems to surface only with the build from emendelson's ZIP package,not with my own build... Maybe he can try with an updated build?

@emendelson
Copy link

I've now replaced the copy of NTVDM.EXE in my ZIP archive, and the current version does not produce this problem. See issue 7 for the download page.

@AEAEAEAE4343
Copy link
Author

Hmmm. The new zip didn't even load programs at all. I have checked dbgview and the dll's work properly.
But now i get the initial error of this post. Not only when trying to run NTVDM.EXE but also stuff like COMMAND and EDIT.

@leecher1337
Copy link
Owner

This could mean thta the ldntvdm.dll for 32bit isn't working properly. It needs to be injected into NTVDM.exe as well to patch CSRSS calls and if i.e. AppInit-Hook is not working there, you get the error with setting up environment.
Please check with Process monitor if ldntvdm.dll is also injected into NTVDM.EXE after NTVDM starts.
Verify, that ldntvdm.dll is listed in key AppInit_DLLs in Computer\HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\Windows NT\CurrentVersion\Windows node in the registry.

Did you only replace ntvdm.exe in system32 and syswow64 directory or did a complete reinstallation?
Just replacing the .exe files would have been enough in this case.
Maybe something went wrong during installation. To do a complete reinstallation cycle, you can uninstall via Control Panel application list, then reboot and then install again and reboot again.

@emendelson
Copy link

I just installed the new ZIP on a Windows 10 machine that had never had NTVDMx64 installed before. It works perfectly.

@leecher1337
Copy link
Owner

Closed due to no further response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants