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

PEREAD.EXE Does not work on Windows 10 64 bit #156

Open
electric-socket opened this issue Jan 9, 2021 · 4 comments
Open

PEREAD.EXE Does not work on Windows 10 64 bit #156

electric-socket opened this issue Jan 9, 2021 · 4 comments
Assignees

Comments

@electric-socket
Copy link

is some sort of problem when running peread in that it does not work. I use SUBST to assign drive letters to directories on my computer so I don't have to use long path names. Here are the relevant assignments:

P:: => C:\lazarus\fpc\3.2.0\bin\x86_64-win64 (This is where the Pascal compiler is located)
V:: => C:\Users\Paul\Documents\Programming\pev-0.80-win32 (location of PE tools)

Tried locating both on subst drives:
V:>dir readpe*
Volume in drive V is Windows
Volume Serial Number is 09C8-AE90

Directory of V:\

01/09/2017 09:38 AM 108,224 readpe.exe
1 File(s) 108,224 bytes
0 Dir(s) 271,177,908,224 bytes free

V:>dir p:ppc*
Volume in drive P is Windows
Volume Serial Number is 09C8-AE90

Directory of P:\

07/07/2020 03:59 PM 3,262,464 ppcx64.exe
1 File(s) 3,262,464 bytes
0 Dir(s) 271,177,351,168 bytes free

V:>readpe.exe p:ppcx64.exe
ERROR [-15]: open() failed (No such file or directory)

V:>dir C:\lazarus\fpc\3.2.0\bin\x86_64-win64\ppc*
Volume in drive C is Windows
Volume Serial Number is 09C8-AE90

Directory of C:\lazarus\fpc\3.2.0\bin\x86_64-win64

07/07/2020 03:59 PM 3,262,464 ppcx64.exe
1 File(s) 3,262,464 bytes
0 Dir(s) 271,180,337,152 bytes free

V:>readpe.exe C:\lazarus\fpc\3.2.0\bin\x86_64-win64\ppcx64.exe
assertion "g_format != NULL" failed: file "output.c", line 242, function: output_open_document_with_name
1 [main] readpe 21540 cygwin_exception::open_stackdumpfile: Dumping stack trace to readpe.exe.stackdump

V:>

I'd say that qualifies as an error.

Paul Robinson xdpascal@xdpascal.com or paul@paul-robinson.us
"The lessons of history teach us - if they teach us anything - that no one learns the lessons that history teaches us."

@merces
Copy link
Collaborator

merces commented Jan 11, 2021

Thanks for the report, Paul! We'll investigate.

@jweyrich
Copy link
Contributor

jweyrich commented Jan 12, 2021

@electric-socket did you try building pev from source to check if the problem persists? I'll take a look.

@merces
Copy link
Collaborator

merces commented Jan 12, 2021

It is likely fixed in v0.81. I've downloaded Lazarus IDE (from where I assume this ppcx64.exe binary is from) and couldn't reproduce the problem:

C:\Users\admin\Desktop\pev-0.81-win>subst
P:\: => C:\lazarus\fpc\3.2.0\bin\x86_64-win64\

C:\Users\admin\Desktop\pev-0.81-win>readpe.exe -h dos p:\ppcx64.exe
DOS Header
    Magic number:                    0x5a4d (MZ)
    Bytes in last page:              144
    Pages in file:                   3
    Relocations:                     0
    Size of header in paragraphs:    4
    Minimum extra paragraphs:        0
    Maximum extra paragraphs:        65535
    Initial (relative) SS value:     0
    Initial SP value:                0xb8
    Initial IP value:                0
    Initial (relative) CS value:     0
    Address of relocation table:     0x40
    Overlay number:                  0
    OEM identifier:                  0
    OEM information:                 0
    PE header offset:                0x80

@GoGoOtaku
Copy link
Collaborator

I ran across assertion "g_format != NULL" failed: file "output.c", line 242, function: output_open_document_with_name
the other day. This happens when it finds a pe.conf that points to a plugin folder without any output libraries.
Gave me a major freakout since I thought I just released a broken version. I wanted to test my freshly installed system version from within my build directory (I have some test executables there). But I had run make clean before so the config file pointed to a directory without any plugin libraries.

I don't know if this was the error that had happened here but it seems likely since this is the same error message.
Frankly I will just add the text output to the executable for the next release. That way this at least doesn't happen if no output plugin is specified.

@GoGoOtaku GoGoOtaku self-assigned this May 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants