Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/csound/csound into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
vlazzarini committed Jan 22, 2015
2 parents 3e2acb1 + fc11edc commit 1b0f507
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 13 deletions.
7 changes: 4 additions & 3 deletions Opcodes/dssi4cs/src/dssi4cs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1034,9 +1034,10 @@ LADSPAPluginSearch(CSOUND *csound,
pcEnd++;

pcBuffer = csound->Malloc(csound, 1 + (pcEnd - pcStart));
if (pcEnd > pcStart)
strlcpy(pcBuffer, pcStart, 1+ pcEnd - pcStart);

if (pcEnd > pcStart) {
strncpy(pcBuffer, pcStart, pcEnd - pcStart);
pcBuffer[pcEnd - pcStart] = '\0';
}
LADSPADirectoryPluginSearch(csound, pcBuffer, fCallbackFunction);
csound->Free(csound, pcBuffer);

Expand Down
12 changes: 6 additions & 6 deletions Opcodes/jacko.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -518,12 +518,12 @@ struct JackoState
csound = csound_;
csoundFramesPerTick = csound->GetKsmps(csound);
csoundFramesPerSecond = csound->GetSr(csound);
result = pthread_mutex_init(&conditionMutex, 0);
result = pthread_cond_init(&csoundCondition, 0);
result = pthread_cond_init(&closeCondition, 0);
result |= pthread_mutex_init(&conditionMutex, 0);
result |= pthread_cond_init(&csoundCondition, 0);
result |= pthread_cond_init(&closeCondition, 0);
// Create a thread to run the close routine. It will immediately
// block until it is signaled.
result = pthread_create(&closeThread, 0, &JackoState::closeRoutine_, this);
result |= pthread_create(&closeThread, 0, &JackoState::closeRoutine_, this);
std::memset(&jack_position, 0, sizeof(jack_position_t));
jack_options_t jack_options = (jack_options_t) (JackServerName |
JackNoStartServer |
Expand Down Expand Up @@ -563,8 +563,8 @@ struct JackoState
}
jackoStatesForCsoundInstances[csound] = this;
csound->RegisterSenseEventCallback(csound, SenseEventCallback_, this);
result = jack_set_process_callback(jackClient, JackProcessCallback_, this);
result = jack_activate(jackClient);
result |= jack_set_process_callback(jackClient, JackProcessCallback_, this);
result |= jack_activate(jackClient);
if (!result) {
csound->Message(csound,
Str("Activated Jack client \"%s\".\n"),
Expand Down
2 changes: 1 addition & 1 deletion Opcodes/pitch.c
Original file line number Diff line number Diff line change
Expand Up @@ -2033,7 +2033,7 @@ int trnsegr(CSOUND *csound, TRANSEG *p)
goto newm; /* and set new curmlt */
}
if (--p->curcnt <= 0) { /* if done cur segment */
segp = p->cursegp;
//segp = p->cursegp; /* overwritten later -- coverity */
chk1:
if (p->segsrem == 2) goto putk; /* seg Y rpts lastval */
if (UNLIKELY(!--p->segsrem)) { /* if none left */
Expand Down
7 changes: 5 additions & 2 deletions frontends/CsoundAC/allegro.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,11 @@ void Alg_atoms::expand()
maxlen += (maxlen >> 2); // add 25%
Alg_attribute *new_atoms = new Alg_attribute[maxlen];
// now do copy
memcpy(new_atoms, atoms, len * sizeof(Alg_attribute));
if (atoms) delete[] atoms;
// **** Suggested fix -- JPff
if (atoms) {
memcpy(new_atoms, atoms, len * sizeof(Alg_attribute));
delete[] atoms;
}
atoms = new_atoms;
}

Expand Down
1 change: 0 additions & 1 deletion interfaces/csPerfThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,6 @@ class CsPerfThreadMsg_StopRecord: public CsoundPerformanceThreadMessage {
}
~CsPerfThreadMsg_StopRecord(){}
private:
bool start;
};


Expand Down

0 comments on commit 1b0f507

Please sign in to comment.