diff options
author | se <se@FreeBSD.org> | 2007-06-03 23:45:31 +0800 |
---|---|---|
committer | se <se@FreeBSD.org> | 2007-06-03 23:45:31 +0800 |
commit | 5df1e93e3556a29e7e4af8f2cb0cf8573bca8bf7 (patch) | |
tree | 2d95030e01c5a0e0b94865473513778bf5c9b722 /multimedia/dvbcut | |
parent | 17d31d815760fa14b5ecab3576fb940f3db23e99 (diff) | |
download | freebsd-ports-gnome-5df1e93e3556a29e7e4af8f2cb0cf8573bca8bf7.tar.gz freebsd-ports-gnome-5df1e93e3556a29e7e4af8f2cb0cf8573bca8bf7.tar.zst freebsd-ports-gnome-5df1e93e3556a29e7e4af8f2cb0cf8573bca8bf7.zip |
Unreak compilation with gcc-4.2: There is one expression containing a
binary operator '>?' that is accepted by gcc-3.x but not by gcc-4.2.
I did not find the definition of this operator and do not know whether
it is an extension found in g++-3.x, but I assume that it is a maximum
value operator (a >? b) <==> max(a, b) and this patch implements this
operation explicitly instead of via the (unknown in g++-4.2) operator.
Submitted by: pointyhat via kris
Diffstat (limited to 'multimedia/dvbcut')
-rw-r--r-- | multimedia/dvbcut/files/patch-playaudio.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/multimedia/dvbcut/files/patch-playaudio.cpp b/multimedia/dvbcut/files/patch-playaudio.cpp new file mode 100644 index 000000000000..50b2cf42c124 --- /dev/null +++ b/multimedia/dvbcut/files/patch-playaudio.cpp @@ -0,0 +1,14 @@ +--- src/playaudio.cpp~ Fri Apr 13 19:36:27 2007 ++++ src/playaudio.cpp Sat Jun 2 20:51:00 2007 +@@ -38,7 +38,10 @@ + const uint8_t *d=(const uint8_t*)data; + + while (len>0) { +- int16_t samples[MIN_BUFFER_SAMPLES >? avcc->frame_size]; ++ int samples_dim = avcc->frame_size; ++ if (samples_dim < MIN_BUFFER_SAMPLES) ++ samples_dim = MIN_BUFFER_SAMPLES; ++ int16_t samples[samples_dim]; + int frame_size; + + int bytesDecoded=avcodec_decode_audio(avcc,samples,&frame_size,(uint8_t*)d,len); |