veandco / go-sdl2

SDL2 binding for Go
https://godoc.org/github.com/veandco/go-sdl2
BSD 3-Clause "New" or "Revised" License
2.2k stars 218 forks source link

AudioStream.Clear returns an error #380

Closed gonutz closed 5 years ago

gonutz commented 5 years ago

In the current SDL_audio.h, line 602, the function SDL_AudioStreamFlush is defined as

extern DECLSPEC void SDLCALL SDL_AudioStreamClear(SDL_AudioStream *stream);

with the return type void. In your implementation however, you use its return value to generate an error. How does this even compile? Am I missing something here? Should it not return nothing instead of error?

dedalqq commented 5 years ago

duplicate: https://github.com/veandco/go-sdl2/issues/379

gonutz commented 5 years ago

Oh I see, closing this one then.