summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Rondeau2011-09-09 16:34:11 -0400
committerTom Rondeau2011-09-09 17:15:37 -0400
commitfc2865413eb271534820137779302b8668335234 (patch)
tree8865b4460f0dd68561672101860adf0d38edaf9e
parent24bdbc8d2d7331ef2a9555269d3f3219de3638b2 (diff)
downloadgnuradio-fc2865413eb271534820137779302b8668335234.tar.gz
gnuradio-fc2865413eb271534820137779302b8668335234.tar.bz2
gnuradio-fc2865413eb271534820137779302b8668335234.zip
tags: fixed fwrite line for the right item size number.
-rw-r--r--gnuradio-core/src/lib/io/gr_tagged_file_sink.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/gnuradio-core/src/lib/io/gr_tagged_file_sink.cc b/gnuradio-core/src/lib/io/gr_tagged_file_sink.cc
index 91618bad6..67184b9c5 100644
--- a/gnuradio-core/src/lib/io/gr_tagged_file_sink.cc
+++ b/gnuradio-core/src/lib/io/gr_tagged_file_sink.cc
@@ -183,7 +183,8 @@ gr_tagged_file_sink::work (int noutput_items,
//std::cout << "Found end of burst: "
// << idx_stop << ", " << N << std::endl;
- int count = fwrite (&inbuf[d_itemsize*idx], d_itemsize, idx_stop-idx, d_handle);
+ int count = fwrite (&inbuf[d_itemsize*idx], d_itemsize,
+ idx_stop-idx, d_handle);
if (count == 0) {
if(ferror(d_handle)) {
perror("gr_tagged_file_sink: error writing file");
@@ -200,7 +201,8 @@ gr_tagged_file_sink::work (int noutput_items,
}
}
if(d_state == IN_BURST) {
- int count = fwrite (&inbuf[idx], d_itemsize, noutput_items-idx, d_handle);
+ int count = fwrite (&inbuf[d_itemsize*idx], d_itemsize,
+ noutput_items-idx, d_handle);
if (count == 0) {
if(ferror(d_handle)) {
perror("gr_tagged_file_sink: error writing file");