diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2011-09-30 17:55:14 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2011-09-30 17:55:14 +0000 |
commit | 0938a42440cc82ce8d0cb064840c258c863714ab (patch) | |
tree | 19f58c31e65226d85c76d96647a6e300f7995c10 /libs/evoral | |
parent | 15e390ebe5611b5443eb1fb57631826389ffd021 (diff) |
fixes for 98% of all the warnings/errors reported by OS X gcc on tiger
git-svn-id: svn://localhost/ardour2/branches/3.0@10179 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/evoral')
-rw-r--r-- | libs/evoral/evoral/PatchChange.hpp | 4 | ||||
-rw-r--r-- | libs/evoral/src/ControlSet.cpp | 2 | ||||
-rw-r--r-- | libs/evoral/src/Sequence.cpp | 2 | ||||
-rw-r--r-- | libs/evoral/src/libsmf/smf_load.c | 9 | ||||
-rw-r--r-- | libs/evoral/src/libsmf/smf_save.c | 1 |
5 files changed, 12 insertions, 6 deletions
diff --git a/libs/evoral/evoral/PatchChange.hpp b/libs/evoral/evoral/PatchChange.hpp index 576a1d2e98..aaa481516f 100644 --- a/libs/evoral/evoral/PatchChange.hpp +++ b/libs/evoral/evoral/PatchChange.hpp @@ -146,7 +146,9 @@ public: case 2: return _program_change; default: - assert (false); + abort (); + /*NOTREACHED*/ + return _program_change; } } diff --git a/libs/evoral/src/ControlSet.cpp b/libs/evoral/src/ControlSet.cpp index 6b793a08ea..bdc73121d2 100644 --- a/libs/evoral/src/ControlSet.cpp +++ b/libs/evoral/src/ControlSet.cpp @@ -32,7 +32,7 @@ ControlSet::ControlSet() { } -ControlSet::ControlSet (const ControlSet& other) +ControlSet::ControlSet (const ControlSet&) : noncopyable () { /* derived class must copy controls */ diff --git a/libs/evoral/src/Sequence.cpp b/libs/evoral/src/Sequence.cpp index fb10bfac7b..a7d58348e2 100644 --- a/libs/evoral/src/Sequence.cpp +++ b/libs/evoral/src/Sequence.cpp @@ -1249,7 +1249,7 @@ template<typename Time> void Sequence<Time>::dump (ostream& str) const { - Sequence<Time>::const_iterator i; + typename Sequence<Time>::const_iterator i; str << "+++ dump\n"; for (i = begin(); i != end(); ++i) { str << *i << endl; diff --git a/libs/evoral/src/libsmf/smf_load.c b/libs/evoral/src/libsmf/smf_load.c index 060dc5849e..90a22509b5 100644 --- a/libs/evoral/src/libsmf/smf_load.c +++ b/libs/evoral/src/libsmf/smf_load.c @@ -275,7 +275,8 @@ is_escape_byte(const unsigned char status) static int32_t expected_sysex_length(const unsigned char status, const unsigned char *second_byte, const size_t buffer_length, int32_t *consumed_bytes) { - uint32_t sysex_length, len; + uint32_t sysex_length = 0; + uint32_t len = 0; assert(status == 0xF0); @@ -424,7 +425,8 @@ extract_escaped_event(const unsigned char *buf, const size_t buffer_length, smf_ (void) last_status; int status; - int32_t message_length, vlq_length; + int32_t message_length = 0; + int32_t vlq_length = 0; const unsigned char *c = buf; status = *buf; @@ -645,7 +647,8 @@ smf_event_is_textual(const smf_event_t *event) char * smf_event_extract_text(const smf_event_t *event) { - uint32_t string_length, length_length; + uint32_t string_length = 0; + uint32_t length_length = 0; if (!smf_event_is_textual(event)) return (NULL); diff --git a/libs/evoral/src/libsmf/smf_save.c b/libs/evoral/src/libsmf/smf_save.c index b99af75461..0540232707 100644 --- a/libs/evoral/src/libsmf/smf_save.c +++ b/libs/evoral/src/libsmf/smf_save.c @@ -180,6 +180,7 @@ smf_format_vlq(unsigned char *buf, int length, unsigned long value) } assert(i <= length); + length = length; // get rid of stupid gcc warnings about unused params if assert() is null /* + 1, because "i" is an offset, not a count. */ return (i + 1); |