• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Mac OSX ds_grid_write / read bug with empty strings

H

Homunculus

Guest
Since it's pretty clear to me that this is a bug, I already reported it. I just wanted to report here too, since it is a really specific problem that may cause some serious headache if encountered (it did to me for sure). I don't know honestly if it's just a mac runner issue or a generalized problem.

Anyways, in short: loading a ds_grid holding empty strings with ds_grid_read, and trying to use one of those empty string values in a data structure that ends up in a json_encode, causes the runner to crash. Sample code:

Code:
var _grid = ds_grid_create(1,1);
_grid[# 0,0] = "";
var _grid_data = ds_grid_write(_grid);
ds_grid_read(_grid,_grid_data);

var _map = ds_map_create();
_map[? "value"] = _grid[# 0,0];

json_encode(_map); //causes crash
 
M

msrojas

Guest
The same happens to me but using file_find_first. If it doesn't found the file and I try to print the output (an empty string) it crash.

I use Windows.
 
H

Homunculus

Guest
as in my case, I suppose the string is set to null instead of empty. Have you reported the issue?
 
Top