Andrew Rose wrote: > I've got a background project to try to get GNU Radio working with the > native Windows tool chain (see > http://www.gnuradio.org/trac/wiki/WindowsNativeInstall). As a > side-effect of using a different compiler, I get different > warnings/errors. > > Here's something I found that's almost certainly wrong. From svn trunk, > gnuradio-core\src\lib\general\gr_test.cc, line 143. > > //Now copy input to output untill max ninputs or max noutputs is > reached > int common_nports=std::min(ninputs,noutputs); > if(d_sizeof_output_item==d_sizeof_input_item); > for (int i = 0; i < common_nports; i++) > { > > memcpy(output_items[i],input_items[i],noutput_items*d_sizeof_input_item) > ; > } > int noutput_items_produced=0; > > The fix appears to be trivial (remove the semicolon at the end of the > if(...) line). However, I don't want to make the fix myself because I > can't test it (because I'm still a long way off having a working build). > I don't know if it would break any existing QAs.
Yes this was very wrong and could result in segfaults when d_sizeof_output_item!=d_sizeof_input_item. I committed the fix. > I thought I'd flag it up in case it might be causing anybody any > problems. (If you fix it, why not change, untill -> until in the > comment too.) > > Andrew Thanks, fixed that too ;-) Greetings, Martin > > > _______________________________________________ > Discuss-gnuradio mailing list > Discuss-gnuradio@gnu.org > http://lists.gnu.org/mailman/listinfo/discuss-gnuradio > _______________________________________________ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnuradio