Merge branch 'master' into windows+cc
[ardour.git] / libs / ardour / midi_track.cc
index f88c331c2ca8a0e7b171b7f1a4aea9a5f9ac7ba9..6a998de90e42b1c1565a3fbf938b4dcd03836ab6 100644 (file)
@@ -17,8 +17,7 @@
     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 */
 
-#include <strings.h> // for ffs(3)
-
+#include "pbd/ffs.h"
 #include "pbd/enumwriter.h"
 #include "pbd/convert.h"
 #include "evoral/midi_util.h"
@@ -513,7 +512,7 @@ MidiTrack::filter_channels (BufferSet& bufs, ChannelMode mode, uint32_t mask)
                                }
                                break;
                        case ForceChannel:
-                               ev.set_channel (ffs (mask) - 1);
+                               ev.set_channel (PBD::ffs (mask) - 1);
                                ++e;
                                break;
                        case AllChannels:
@@ -633,9 +632,9 @@ void
 MidiTrack::MidiControl::set_value(double val)
 {
        bool valid = false;
-       if (std::isinf(val)) {
+       if (isinf(val)) {
                cerr << "MIDIControl value is infinity" << endl;
-       } else if (std::isnan(val)) {
+       } else if (isnan(val)) {
                cerr << "MIDIControl value is NaN" << endl;
        } else if (val < _list->parameter().min()) {
                cerr << "MIDIControl value is < " << _list->parameter().min() << endl;