dchanman / minecraft_go

Minecraft Geocaching with Altera FPGAs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Remove malloc call from gps.c

dchanman opened this issue · comments

Only noticed this after doing all the merging settled. This issue is just as a placeholder so we don't forget to make the change.

We should remove malloc calls and instead have the caller function provide a reference instead (as indicated in your comment). I agree with you that be better for performance and that we don't want to deal with memory leaks.

Code ref: https://github.com/dchanman/cpen391-21/blob/master/minecraft_go/software/mc_go/src/gps.c#L40