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

[Bug] plistutil cannot read from stdin - ERROR: Could not parse plist data (-3) #254

Open
mast3rz3ro opened this issue Feb 3, 2024 · 0 comments

Comments

@mast3rz3ro
Copy link

Hi there,

The read from stdin seems to be broken when libplist are compiled with MINGW64 !
compiling with MSYS2 seems to solve this issue but I would like to get this working with MINGW64 and MINGW32 if possible. because it's will allow to build it without depending on msys-2.0.dll.

Please note that the MSYS2 comes with many different interfaces, e.g MSYS2 and MINGW64 each one has different environments.

The output i got when running the version compiled by MINGW64:

$ cat temp.plist | plistutil.exe -i -
$ ERROR: Could not parse plist data, expected XML or binary plist

$ cat temp.plist | plistutil.exe -p -
$ ERROR: Could not parse plist data (-3)

$ ldd /mingw64/bin/plistutil.exe
        ntdll.dll => /c/Windows/SYSTEM32/ntdll.dll (0x76f30000)
        kernel32.dll => /c/Windows/system32/kernel32.dll (0x76d10000)
        KERNELBASE.dll => /c/Windows/system32/KERNELBASE.dll (0x7fefcc60000)
        libplist-2.0.dll => /mingw64/bin/libplist-2.0.dll (0x7feef210000)
        msvcrt.dll => /c/Windows/system32/msvcrt.dll (0x7fefd2e0000)

$ ./plistutil.exe -v
plistutil 2.3.0-28-g3daee60

The output when compiled with MSYS2:

It's even runs in microsoft's cmd:
> type temp.plist | plistutil.exe -p -

$ ldd /usr/bin/plistutil.exe
        ntdll.dll => /c/Windows/SYSTEM32/ntdll.dll (0x76f30000)
        kernel32.dll => /c/Windows/system32/kernel32.dll (0x76d10000)
        KERNELBASE.dll => /c/Windows/system32/KERNELBASE.dll (0x7fefcc60000)
        msys-plist-2.0-4.dll => /usr/bin/msys-plist-2.0-4.dll (0x4b98e0000)
        msys-2.0.dll => /usr/bin/msys-2.0.dll (0x180040000)

$ ./tools/plistutil.exe -v
plistutil 2.3.0-28-g3daee60

Thank you for everything !

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

1 participant