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

Overall cleanup. #387

Merged
merged 3 commits into from Mar 14, 2019
Merged

Overall cleanup. #387

merged 3 commits into from Mar 14, 2019

Conversation

denisfa
Copy link
Collaborator

@denisfa denisfa commented Mar 13, 2019

@rkitover This is a little bit of cleanup. On #94 we discussed about managing a single config file for all platforms (vbam.ini), so we needed to also include a migration path for vbam.cfg on MacOS and Windows.

We also had some stuff duplicated the FILE_SEP, like ${XDG_CONFIG_HOME}//visualboyadvance-m from the xdg functions. Although it has no problem, since all platforms understand the duplicate FILE_SEP, it was a quick fix, so why not?

Finally, it is always a good practice to set a pointer to NULL after deallocating it. This was missing from the variable home that was the cause of that segfault command line issue.

@rkitover
Copy link
Collaborator

All of this looks fine to me. I'm not sure about a .cfg extension on windows, I don't think it ever used that, but that's ok.

Also this change for home does not fix the exit code, I have not yet figured out where that comes from, you can test it like this:

./visualboyadvance-m --help; echo $?

Also on windows / path separators are fine and understood by the POSIX layer, although using the backslashes is preferred.

Will merge this now.

@rkitover rkitover merged commit 3fd444d into visualboyadvance-m:master Mar 14, 2019
@denisfa denisfa deleted the overall-fixes branch March 14, 2019 10:38
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

Successfully merging this pull request may close these issues.

None yet

2 participants