View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0028224||Runner||Android||Public||2017-11-06 15:15||2018-06-27 11:36|
|Reporter||Stewart Bishop||Assigned To||Alan Savage|
|Priority||High||Severity||A - Crash/Hang||Reproducibility||100%|
|Target Version||Fixed in Version||Pre-2.1.3|
|Summary||0028224: Android: Extension crashes game because http_post_string() fails with return code 404 and an IOException|
|Description||I wrote a wrapper for the online highscore services of globalstats.io.|
It's available on the Marketplace too (https://marketplace.yoyogames.com/assets/4973/globalstats-io-gm) and downloaded more than 100 times.
The wrapper works fine under Windows and HTML5 but dies with an IOException and a 404 when started on an Android device (customers reported several devices, I can reproduce 100% on an Samsung Galaxy A3 2016).
The first http_post_string() fails with return code 404 and an IOException. Afterwards the APK just terminates.
To reproduce just load the exported project (see Sample URL) and test on an Android device. It will crash after gs_getAccessToken() is called. The HTTP event in oGlobalStatsIOController handles the response and shows the IOException and then the APK dies.
On Windows and HTML5 the same code just works fine. So it's not a problem of the URL or the server in the backend but it must be in the Android wrapper code.
Any help from your side highly appreciated.
This error occurs with the latest GMS2 and also with the latest GM:S 1.4 release on Android.
|Steps To Reproduce||1) Run project on Android|
2) Click play
3) Wait 30 seconds
4) Game crashes
|Tags||No tags attached.|
|1.4 Found In||1.4.1772|
|2.x Runtime Found In||18.104.22.168|
|2.x Runtime Verified In||22.214.171.124|
http_post_string appears to be working correctly, possibly fixed RE 0027116;
fixed an issue with http_request when posting a string which was causing an exception when the content length was set in the header; the sample now functions correctly on Android