mirror of
https://github.com/badaix/snapcast.git
synced 2025-04-29 10:17:16 +02:00
fixed clang warnings (CXX = /usr/bin/clang++)
This commit is contained in:
parent
f11a7055a1
commit
e1a47b3b98
5 changed files with 9 additions and 11 deletions
|
@ -32,8 +32,8 @@ else
|
|||
|
||||
CXX = /usr/bin/g++
|
||||
STRIP = strip
|
||||
CXXFLAGS += -static-libgcc -static-libstdc++ -DHAS_OGG -DHAS_ALSA -DHAS_AVAHI -DHAS_DAEMON
|
||||
LDFLAGS = -lrt -lasound -logg -lvorbis -lFLAC -lavahi-client -lavahi-common
|
||||
CXXFLAGS += -DHAS_OGG -DHAS_ALSA -DHAS_AVAHI -DHAS_DAEMON
|
||||
LDFLAGS = -lrt -lasound -logg -lvorbis -lFLAC -lavahi-client -lavahi-common -static-libgcc -static-libstdc++
|
||||
OBJ += player/alsaPlayer.o decoder/oggDecoder.o browseAvahi.o
|
||||
|
||||
endif
|
||||
|
|
|
@ -50,11 +50,13 @@ PcmChunk::~PcmChunk()
|
|||
|
||||
int PcmChunk::seek(int frames)
|
||||
{
|
||||
if ((frames < 0) && (-frames > (int)idx_))
|
||||
frames = -idx_;
|
||||
|
||||
idx_ += frames;
|
||||
if (idx_ > getFrameCount())
|
||||
idx_ = getFrameCount();
|
||||
if (idx_ < 0)
|
||||
idx_ = 0;
|
||||
|
||||
return idx_;
|
||||
}
|
||||
|
||||
|
|
|
@ -21,8 +21,7 @@ else
|
|||
|
||||
CXX = /usr/bin/g++
|
||||
STRIP = strip
|
||||
CXXFLAGS += -static-libgcc -static-libstdc++
|
||||
LDFLAGS = -lrt -lvorbis -lvorbisenc -logg -lFLAC -lavahi-client -lavahi-common
|
||||
LDFLAGS = -lrt -lvorbis -lvorbisenc -logg -lFLAC -lavahi-client -lavahi-common -static-libgcc -static-libstdc++
|
||||
|
||||
endif
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
using namespace std;
|
||||
|
||||
|
||||
OggEncoder::OggEncoder(const std::string& codecOptions) : Encoder(codecOptions), lastGranulepos(0), eos(0)
|
||||
OggEncoder::OggEncoder(const std::string& codecOptions) : Encoder(codecOptions), lastGranulepos(0)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -180,7 +180,7 @@ void OggEncoder::initEncoder()
|
|||
|
||||
*********************************************************************/
|
||||
|
||||
ret = vorbis_encode_init_vbr(&vi, sampleFormat_.channels, sampleFormat_.rate, quality);
|
||||
int ret = vorbis_encode_init_vbr(&vi, sampleFormat_.channels, sampleFormat_.rate, quality);
|
||||
|
||||
/* do not continue if setup failed; this can happen if we ask for a
|
||||
mode that libVorbis does not support (eg, too low a bitrate, etc,
|
||||
|
|
|
@ -48,9 +48,6 @@ private:
|
|||
vorbis_block vb; /* local working space for packet->PCM decode */
|
||||
|
||||
ogg_int64_t lastGranulepos;
|
||||
|
||||
int eos, ret;
|
||||
int i, founddata;
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue