use SDL_zeroa at more places where the argument is an array.

This commit is contained in:
Ozkan Sezer
2019-07-31 05:11:40 +03:00
parent 7a47c292c0
commit 4953e050f5
12 changed files with 18 additions and 18 deletions

View File

@@ -112,7 +112,7 @@ WaveDebugLogFormat(WaveFile *file)
Uint32 wavebps = format->byterate;
char channelstr[64];
SDL_zero(channelstr);
SDL_zeroa(channelstr);
switch (format->encoding) {
case PCM_CODE:

View File

@@ -619,8 +619,8 @@ QSA_Deinitialize(void)
{
/* Clear devices array on shutdown */
/* !!! FIXME: we zero these on init...any reason to do it here? */
SDL_zero(qsa_playback_device);
SDL_zero(qsa_capture_device);
SDL_zeroa(qsa_playback_device);
SDL_zeroa(qsa_capture_device);
qsa_playback_devices = 0;
qsa_capture_devices = 0;
}
@@ -629,8 +629,8 @@ static int
QSA_Init(SDL_AudioDriverImpl * impl)
{
/* Clear devices array */
SDL_zero(qsa_playback_device);
SDL_zero(qsa_capture_device);
SDL_zeroa(qsa_playback_device);
SDL_zeroa(qsa_capture_device);
qsa_playback_devices = 0;
qsa_capture_devices = 0;

View File

@@ -387,7 +387,7 @@ WINMM_OpenDevice(_THIS, void *handle, const char *devname, int iscapture)
return SDL_OutOfMemory();
}
SDL_zero(this->hidden->wavebuf);
SDL_zeroa(this->hidden->wavebuf);
for (i = 0; i < NUM_BUFFERS; ++i) {
this->hidden->wavebuf[i].dwBufferLength = this->spec.size;
this->hidden->wavebuf[i].dwFlags = WHDR_DONE;