Return-To-The-Roots / s25client

Return To The Roots (Settlers II(R) Clone)
http://www.rttr.info
GNU General Public License v2.0
476 stars 75 forks source link

Fix for 'null' terminal error on macOS Ventura #1546

Closed FixedSpeed closed 1 year ago

FixedSpeed commented 1 year ago

Replaced the deprecated sprintf() with snprintf() function on macOS Ventura to fix the '"rttr.terminal" can't be opened because (null) is not allowed to open documents in Terminal' error.

Fixes #1543

Flamefire commented 1 year ago

Thanks for the PR! However you would need to open a PR against each submodule first and then here once those are merged

Also I'd argue the description and title don't really match what is done/fixed as I doubt this change will fix the 'null' error as that likely comes from the OS and/or (rttr.terminal)[https://github.com/Return-To-The-Roots/s25client/blob/master/extras/macosLauncher/rttr.terminal] for reasons I don't see and (not having access to macOS) I can't check.

Anyway I opened a PR based on your suggestion after which you should be able to at least build RttR. If you find the reason for the terminal error and a fix please open a PR for that. Thanks!

FixedSpeed commented 1 year ago

Ok, thanks for creating the pull request for the submodules. Do you want me to review ?

And yes, I do agree on whether this is the actual fix. At least for me on macOS Ventura I was able to run RttR. But indeed, let's see if the problem is solved after running the actual new release.

Flamefire commented 1 year ago

Feel free to leave remarks for #1547 especially if you still have anything failing due to the same problem but it mostly was a search/replace anyway so I don't expect there would be anything.