rpms/audacious-plugins/F-12 audacious-plugins-2.1-musepack.patch, 1.2, 1.3 audacious-plugins.spec, 1.63, 1.64

Michael Schwendt mschwendt at fedoraproject.org
Tue Nov 17 11:36:16 UTC 2009


Author: mschwendt

Update of /cvs/pkgs/rpms/audacious-plugins/F-12
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv4819

Modified Files:
	audacious-plugins-2.1-musepack.patch audacious-plugins.spec 
Log Message:
* Tue Nov 17 2009 Michael Schwendt <mschwendt at fedoraproject.org> - 2.1-17
- More cleanup in musepack plugin.


audacious-plugins-2.1-musepack.patch:
 libmpc.cxx |   33 +++++++++++++++------------------
 libmpc.h   |    2 +-
 2 files changed, 16 insertions(+), 19 deletions(-)

Index: audacious-plugins-2.1-musepack.patch
===================================================================
RCS file: /cvs/pkgs/rpms/audacious-plugins/F-12/audacious-plugins-2.1-musepack.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -p -r1.2 -r1.3
--- audacious-plugins-2.1-musepack.patch	13 Nov 2009 18:12:01 -0000	1.2
+++ audacious-plugins-2.1-musepack.patch	17 Nov 2009 11:36:14 -0000	1.3
@@ -1,14 +1,16 @@
 diff -Nur audacious-plugins-fedora-2.1-orig/src/musepack/libmpc.cxx audacious-plugins-fedora-2.1-musepack/src/musepack/libmpc.cxx
 --- audacious-plugins-fedora-2.1-orig/src/musepack/libmpc.cxx	2009-07-07 00:40:36.000000000 +0200
-+++ audacious-plugins-fedora-2.1-musepack/src/musepack/libmpc.cxx	2009-11-13 19:08:48.066816546 +0100
-@@ -48,7 +48,6 @@
++++ audacious-plugins-fedora-2.1-musepack/src/musepack/libmpc.cxx	2009-11-17 12:33:49.249924868 +0100
+@@ -48,8 +48,7 @@
  static MpcDecoder   mpcDecoder   = {0};
  static TrackInfo    track        = {0};
  
 -static GThread            *threadHandle;
- static GStaticMutex threadMutex = G_STATIC_MUTEX_INIT;
+-static GStaticMutex threadMutex = G_STATIC_MUTEX_INIT;
++/* static GStaticMutex threadMutex = G_STATIC_MUTEX_INIT; */
  
  /*
+  * VFS callback implementation, adapted from mpc_reader.c.
 @@ -301,24 +300,21 @@
      mpcDecoder.isAlive  = true;
      mpcDecoder.isOutput = false;
@@ -36,25 +38,58 @@ diff -Nur audacious-plugins-fedora-2.1-o
  }
  
  static void mpcPause(InputPlayback *data, short p_Pause)
-@@ -833,8 +829,7 @@
+@@ -823,7 +819,7 @@
+     lockRelease();
+ 
+     gint counter = 2 * track.sampleFreq / 3;
+-    while (isAlive())
++    while (isAlive() && data->playing)
+     {
+         if (getOffset() != -1)
+         {
+@@ -832,18 +828,19 @@
+         }
  
          lockAcquire();
-         short iPlaying = data->output->buffer_playing()? 1 : 0;
+-        short iPlaying = data->output->buffer_playing()? 1 : 0;
 -        gint iFree = data->output->buffer_free();
 -        if (!mpcDecoder.isPause && iFree >= ((1152 * 4) << iPlaying))
 +        if (!mpcDecoder.isPause)
          {
-             unsigned status = processBuffer(data, sampleBuffer, xmmsBuffer, decoder);
-             if (status == (unsigned) (-1))
-@@ -860,7 +855,6 @@
-         else
-         {
+-            unsigned status = processBuffer(data, sampleBuffer, xmmsBuffer, decoder);
+-            if (status == (unsigned) (-1))
++            guint status = processBuffer(data, sampleBuffer, xmmsBuffer, decoder);
++            if (status == (guint)(-1))
+             {
+                 mpcDecoder.isError = g_strdup_printf("[xmms-musepack] error from internal decoder on %s", filename);
+                 return endThread(filename, input, true);
+             }
+-            if (status == 0 && iPlaying == 0)
++            if (status == 0) {
+                 return endThread(filename, input, true);
++                data->eof = TRUE;
++                data->playing = FALSE;
++            }
+ 
              lockRelease();
--            g_usleep(10000);
-         }
-     }
+ 
+@@ -866,13 +863,13 @@
      return endThread(filename, input, false);
-@@ -911,12 +905,12 @@
+ }
+ 
+-static int processBuffer(InputPlayback *playback, 
++static guint processBuffer(InputPlayback *playback, 
+     MPC_SAMPLE_FORMAT* sampleBuffer, char* xmmsBuffer, mpc_decoder& decoder)
+ {
+     mpc_uint32_t vbrAcc = 0;
+     mpc_uint32_t vbrUpd = 0;
+ 
+-    unsigned status  = mpc_decoder_decode(&decoder, sampleBuffer, &vbrAcc, &vbrUpd);
++    guint status = mpc_decoder_decode(&decoder, sampleBuffer, &vbrAcc, &vbrUpd);
+     copyBuffer(sampleBuffer, xmmsBuffer, status);
+ 
+     if (pluginConfig.dynamicBitrate)
+@@ -911,12 +908,12 @@
  
  inline static void lockAcquire()
  {
@@ -69,3 +104,15 @@ diff -Nur audacious-plugins-fedora-2.1-o
  }
  
  inline static bool isAlive()
+diff -Nur audacious-plugins-fedora-2.1-orig/src/musepack/libmpc.h audacious-plugins-fedora-2.1-musepack/src/musepack/libmpc.h
+--- audacious-plugins-fedora-2.1-orig/src/musepack/libmpc.h	2009-07-07 00:40:36.000000000 +0200
++++ audacious-plugins-fedora-2.1-musepack/src/musepack/libmpc.h	2009-11-17 12:33:49.249924868 +0100
+@@ -123,7 +123,7 @@
+ static void       lockAcquire();
+ static void       lockRelease();
+ static void*      decodeStream(InputPlayback*);
+-static int        processBuffer(InputPlayback*, MPC_SAMPLE_FORMAT*, char*, mpc_decoder&);
++static guint      processBuffer(InputPlayback*, MPC_SAMPLE_FORMAT*, char*, mpc_decoder&);
+ //static void*      endThread(char*, FILE*, bool);
+ static bool       isAlive();
+ static void       setAlive(bool);


Index: audacious-plugins.spec
===================================================================
RCS file: /cvs/pkgs/rpms/audacious-plugins/F-12/audacious-plugins.spec,v
retrieving revision 1.63
retrieving revision 1.64
diff -u -p -r1.63 -r1.64
--- audacious-plugins.spec	13 Nov 2009 18:12:01 -0000	1.63
+++ audacious-plugins.spec	17 Nov 2009 11:36:15 -0000	1.64
@@ -5,7 +5,7 @@
 
 Name: audacious-plugins
 Version: 2.1
-Release: 16%{?dist}
+Release: 17%{?dist}
 Summary: Plugins for the Audacious media player
 Group: Applications/Multimedia
 URL: http://audacious-media-player.org/
@@ -251,6 +251,9 @@ rm -rf $RPM_BUILD_ROOT
 
 
 %changelog
+* Tue Nov 17 2009 Michael Schwendt <mschwendt at fedoraproject.org> - 2.1-17
+- More cleanup in musepack plugin.
+
 * Fri Nov 13 2009 Michael Schwendt <mschwendt at fedoraproject.org> - 2.1-16
 - Make musepack output time work.
 - Patch musepack plugin to remove old cruft and fix playback.




More information about the scm-commits mailing list