rpms/audacious-plugins/F-10 audacious-plugins-1.5.1-musepack.patch, 1.1, 1.2 audacious-plugins.spec, 1.42, 1.43

Michael Schwendt mschwendt at fedoraproject.org
Tue Nov 17 11:49:42 UTC 2009


Author: mschwendt

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

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


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

Index: audacious-plugins-1.5.1-musepack.patch
===================================================================
RCS file: /cvs/pkgs/rpms/audacious-plugins/F-10/audacious-plugins-1.5.1-musepack.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- audacious-plugins-1.5.1-musepack.patch	13 Nov 2009 16:34:03 -0000	1.1
+++ audacious-plugins-1.5.1-musepack.patch	17 Nov 2009 11:49:41 -0000	1.2
@@ -1,23 +1,27 @@
-diff -Nur audacious-plugins-fedora-1.5.1-orig/src/musepack/libmpc.cxx audacious-plugins-1.5.1-musepack/src/musepack/libmpc.cxx
+diff -Nur audacious-plugins-fedora-1.5.1-orig/src/musepack/libmpc.cxx audacious-plugins-fedora-1.5.1-musepack/src/musepack/libmpc.cxx
 --- audacious-plugins-fedora-1.5.1-orig/src/musepack/libmpc.cxx	2008-06-08 10:37:44.000000000 +0200
-+++ audacious-plugins-1.5.1-musepack/src/musepack/libmpc.cxx	2009-11-13 17:28:25.000000000 +0100
-@@ -52,7 +52,6 @@
++++ audacious-plugins-fedora-1.5.1-musepack/src/musepack/libmpc.cxx	2009-11-17 12:43:47.459927692 +0100
+@@ -52,8 +52,7 @@
  static MpcDecoder   mpcDecoder   = {0};
  static TrackInfo    track        = {0};
  
 -static GThread            *threadHandle;
- GStaticMutex threadMutex = G_STATIC_MUTEX_INIT;
+-GStaticMutex threadMutex = G_STATIC_MUTEX_INIT;
++/* GStaticMutex threadMutex = G_STATIC_MUTEX_INIT; */
  
  /*
-@@ -305,7 +304,6 @@
+  * VFS callback implementation, adapted from mpc_reader.c.
+@@ -305,24 +304,21 @@
      mpcDecoder.isAlive  = true;
      mpcDecoder.isOutput = false;
      mpcDecoder.isPause  = false;
 -    threadHandle = g_thread_self();
++    data->playing = TRUE;
      data->set_pb_ready(data);
      decodeStream(data);
++    data->playing = FALSE;
  }
-@@ -313,16 +311,12 @@
+ 
  static void mpcStop(InputPlayback *data)
  {
      setAlive(false);
@@ -34,25 +38,58 @@ diff -Nur audacious-plugins-fedora-1.5.1
  }
  
  static void mpcPause(InputPlayback *data, short p_Pause)
-@@ -837,8 +831,7 @@
+@@ -827,7 +823,7 @@
+     lockRelease();
+ 
+     gint counter = 2 * track.sampleFreq / 3;
+-    while (isAlive())
++    while (isAlive() && data->playing)
+     {
+         if (getOffset() != -1)
+         {
+@@ -836,18 +832,19 @@
+         }
  
          lockAcquire();
-         short iPlaying = MpcPlugin.output->buffer_playing()? 1 : 0;
+-        short iPlaying = MpcPlugin.output->buffer_playing()? 1 : 0;
 -        gint iFree = MpcPlugin.output->buffer_free();
 -        if (!mpcDecoder.isPause &&  iFree >= ((1152 * 4) << iPlaying))
 +        if (!mpcDecoder.isPause)
          {
-             unsigned status = processBuffer(data, sampleBuffer, xmmsBuffer, decoder);
-             if (status == (unsigned) (-1))
-@@ -864,7 +857,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) {
++                data->eof = TRUE;
++                data->playing = FALSE;
+                 return endThread(filename, input, true);
++            }
+ 
              lockRelease();
--            g_usleep(10000);
-         }
-     }
+ 
+@@ -870,13 +867,13 @@
      return endThread(filename, input, false);
-@@ -915,12 +907,12 @@
+ }
+ 
+-static int processBuffer(InputPlayback *playback, 
++static gint 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)
+@@ -915,12 +912,12 @@
  
  inline static void lockAcquire()
  {
@@ -67,3 +104,15 @@ diff -Nur audacious-plugins-fedora-1.5.1
  }
  
  inline static bool isAlive()
+diff -Nur audacious-plugins-fedora-1.5.1-orig/src/musepack/libmpc.h audacious-plugins-fedora-1.5.1-musepack/src/musepack/libmpc.h
+--- audacious-plugins-fedora-1.5.1-orig/src/musepack/libmpc.h	2008-06-08 10:37:44.000000000 +0200
++++ audacious-plugins-fedora-1.5.1-musepack/src/musepack/libmpc.h	2009-11-17 12:42:28.035927069 +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-10/audacious-plugins.spec,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -p -r1.42 -r1.43
--- audacious-plugins.spec	13 Nov 2009 16:34:03 -0000	1.42
+++ audacious-plugins.spec	17 Nov 2009 11:49:41 -0000	1.43
@@ -4,7 +4,7 @@
 
 Name:           audacious-plugins
 Version:        1.5.1
-Release:        16%{?dist}
+Release:        17%{?dist}
 Summary:        Plugins for the Audacious media player
 Group:          Applications/Multimedia
 
@@ -287,6 +287,9 @@ update-desktop-database &> /dev/null || 
 
 
 %changelog
+* Tue Nov 17 2009 Michael Schwendt <mschwendt at fedoraproject.org> - 1.5.1-17
+- More cleanup in musepack plugin.
+
 * Fri Nov 13 2009 Michael Schwendt <mschwendt at fedoraproject.org> - 1.5.1-16
 - Patch musepack plugin to remove old cruft and fix playback.
 - Patch modplug plugin to remove old cruft and fix playback.




More information about the fedora-extras-commits mailing list