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

CXI extraction produces errors if ExeFS path not set #16

Closed
EddyK28 opened this issue Sep 2, 2018 · 0 comments
Closed

CXI extraction produces errors if ExeFS path not set #16

EddyK28 opened this issue Sep 2, 2018 · 0 comments

Comments

@EddyK28
Copy link

EddyK28 commented Sep 2, 2018

3dstool produces errors and exits in an error state when extracting a cxi file if not extracting the ExeFS. The content is still extracted successfully, but the error state causes issues for scripts which rely on exit state to determine extraction success. No errors are produced if the ExeFS is extracted as well, even if to NUL or /dev/null.

Steps to Reproduce:

Extract any contents from a cxi file excluding the ExeFS.
eg. 3dstool -xvtf cxi "test.cxi" --header header.bin --extendedheader exheader.bin

Expected Results:

Selected contents are extracted without error.

Actual Results:

Selected contents are extracted, but program produces errors: ERROR: open file failed and ERROR: extract file failed

Additional Info:

It appears that m_sExeFsFileName is not checked to contain a path prior to an attempted file open (ncch.cpp:189), causing these errors.

Example of extract with errors:

E:\Citra\Games>3dstool -xvtf cxi "Pokemon SMD.cxi" --header header.bin --extendedheader exheader.bin
save: header.bin
save: exheader.bin
INFO: logoregion is not extract
INFO: plainregion is not extract
ERROR: open file  failed

INFO: romfs is not extract
ERROR: extract file failed

Example of extract without errors:

E:\Citra\Games>3dstool -xvtf cxi "Pokemon SMD.cxi" --header header.bin --extendedheader exheader.bin --exefs exefs.bin
save: header.bin
save: exheader.bin
INFO: logoregion is not extract
INFO: plainregion is not extract
save: exefs.bin
INFO: romfs is not extract

On an unrelated note, would you consider adding a license to this repo? (maybe MIT or zlib?)

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

2 participants