Use DEBUG_THREAD_SELF when using DEBUG_TRACE with pthread IDs
authorJohn Emmas <johne53@tiscali.co.uk>
Wed, 10 Dec 2014 16:53:47 +0000 (16:53 +0000)
committerJohn Emmas <johne53@tiscali.co.uk>
Wed, 10 Dec 2014 16:56:33 +0000 (16:56 +0000)
(supports both normal pthreads usage and PTW32)

libs/ardour/audio_diskstream.cc

index 538faebc4f9375d9c24a9d78d201390a77921e35..4c3f7e6437f6f859d7fb97cc715714bca6670610 100644 (file)
@@ -514,7 +514,7 @@ AudioDiskstream::process (BufferSet& bufs, framepos_t transport_frame, pframes_t
 
                                if (rec_nframes > total) {
                                         DEBUG_TRACE (DEBUG::Butler, string_compose ("%1 overrun in %2, rec_nframes = %3 total space = %4\n",
-                                                                                    pthread_self(), name(), rec_nframes, total));
+                                                                                    DEBUG_THREAD_SELF, name(), rec_nframes, total));
                                        DiskOverrun ();
                                        return -1;
                                }
@@ -622,7 +622,7 @@ AudioDiskstream::process (BufferSet& bufs, framepos_t transport_frame, pframes_t
                                        cerr << _name << " Need " << necessary_samples << " total = " << total << endl;
                                        cerr << "underrun for " << _name << endl;
                                         DEBUG_TRACE (DEBUG::Butler, string_compose ("%1 underrun in %2, rec_nframes = %3 total space = %4\n",
-                                                                                    pthread_self(), name(), rec_nframes, total));
+                                                                                    DEBUG_THREAD_SELF, name(), rec_nframes, total));
                                        DiskUnderrun ();
                                        return -1;