mirror of
https://github.com/ZDoom/fluidsynth.git
synced 2024-12-03 01:22:31 +00:00
optimize null check for older compilers
This commit is contained in:
parent
aba36a6ea5
commit
5ee154c6ac
1 changed files with 12 additions and 6 deletions
|
@ -2521,12 +2521,15 @@ fluid_synth_nwrite_float(fluid_synth_t* synth, int len,
|
|||
FLUID_MEMCPY(fx_right[i], fx_right_in[i] + synth->cur, bytes);
|
||||
#else //WITH_FLOAT
|
||||
int j;
|
||||
for (j = 0; (fx_left != NULL) && (j < num); j++)
|
||||
if(fx_left != NULL) {
|
||||
for (j = 0; j < num; j++)
|
||||
fx_left[i][j] = (float) fx_left_in[i][j + synth->cur];
|
||||
}
|
||||
|
||||
for (j = 0; (fx_right != NULL) && (j < num); j++)
|
||||
if(fx_right != NULL) {
|
||||
for (j = 0; j < num; j++)
|
||||
fx_right[i][j] = (float) fx_right_in[i][j + synth->cur];
|
||||
|
||||
}
|
||||
#endif //WITH_FLOAT
|
||||
}
|
||||
|
||||
|
@ -2569,12 +2572,15 @@ fluid_synth_nwrite_float(fluid_synth_t* synth, int len,
|
|||
FLUID_MEMCPY(fx_right[i + count], fx_right_in[i], bytes);
|
||||
#else //WITH_FLOAT
|
||||
int j;
|
||||
for (j = 0; (fx_left != NULL) && (j < num); j++)
|
||||
if(fx_left != NULL) {
|
||||
for (j = 0; j < num; j++)
|
||||
fx_left[i][j + count] = (float) fx_left_in[i][j];
|
||||
}
|
||||
|
||||
for (j = 0; (fx_right != NULL) && (j < num); j++)
|
||||
if(fx_right != NULL) {
|
||||
for (j = 0; j < num; j++)
|
||||
fx_right[i][j + count] = (float) fx_right_in[i][j];
|
||||
|
||||
}
|
||||
#endif //WITH_FLOAT
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue