misc: Fix up a few warnings uncovered by LTO

* direct use of memcpy() instead of ci->memcpy() in flac and mod
 * uninitialized variable in mpegplayer

Change-Id: I2d08682d5f66c319780e69e3ff63d600c61d8f5a
This commit is contained in:
Solomon Peachy 2021-07-08 21:08:16 -04:00
parent 4c60bc9e68
commit 144d1b1e81
4 changed files with 15 additions and 18 deletions

View File

@ -369,7 +369,7 @@ void stretch_image_plane(const uint8_t * src, uint8_t *dst, int stride,
bool vo_draw_frame_thumb(uint8_t * const * buf, const struct vo_rect *rc)
{
void *mem;
size_t bufsize;
size_t bufsize = 0;
uint8_t *yuv[3];
struct vo_rect thumb_rc;
int thumb_width, thumb_height;

View File

@ -91,15 +91,15 @@ static bool flac_init(FLACContext* fc, int first_frame_offset)
nseekpoints=0;
fc->sample_skip = 0;
/* Reset sample buffers */
memset(decoded0, 0, sizeof(decoded0));
memset(decoded1, 0, sizeof(decoded1));
memset(decoded2, 0, sizeof(decoded2));
memset(decoded3, 0, sizeof(decoded3));
memset(decoded4, 0, sizeof(decoded4));
memset(decoded5, 0, sizeof(decoded5));
ci->memset(decoded0, 0, sizeof(decoded0));
ci->memset(decoded1, 0, sizeof(decoded1));
ci->memset(decoded2, 0, sizeof(decoded2));
ci->memset(decoded3, 0, sizeof(decoded3));
ci->memset(decoded4, 0, sizeof(decoded4));
ci->memset(decoded5, 0, sizeof(decoded5));
/* Set sample buffers in decoder structure */
fc->decoded[0] = decoded0;
fc->decoded[1] = decoded1;

View File

@ -1,4 +1,4 @@
/* Copyright (C) 2002-2007 Jean-Marc Valin
/* Copyright (C) 2002-2007 Jean-Marc Valin
File: modes.c
Describes the wideband modes of the codec
@ -6,18 +6,18 @@
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
- Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
- Neither the name of the Xiph.org Foundation nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
@ -371,6 +371,3 @@ const SpeexMode * speex_lib_get_mode (int mode)
return speex_mode_list[mode];
}

View File

@ -424,7 +424,7 @@ void initmodplayer(void)
/* Set Default Panning */
mixer_setpanning(c, panningvalues[c]);
/* Reset channels in the MOD Player */
memset(&modplayer.modchannel[c], 0, sizeof(struct s_modchannel));
ci->memset(&modplayer.modchannel[c], 0, sizeof(struct s_modchannel));
/* Don't play anything */
mixer.channel[c].channelactive = false;
}