]> sigrok.org Git - pulseview.git/commitdiff
Fix #599 by supplying correct length to create_logic_packet()
authorSoeren Apel <redacted>
Fri, 31 Jul 2015 05:33:23 +0000 (07:33 +0200)
committerSoeren Apel <redacted>
Fri, 31 Jul 2015 05:33:23 +0000 (07:33 +0200)
pv/storesession.cpp

index bf214554250ac6ddf23185aa61bc448bcbf24e09..e4af5db7bcf40d8b123449a676e472c814f3c9d2 100644 (file)
@@ -198,7 +198,7 @@ void StoreSession::store_proc(shared_ptr<data::LogicSegment> segment)
                        start_sample + samples_per_block, sample_count);
                segment->get_samples(data, start_sample, end_sample);
 
-               size_t length = end_sample - start_sample;
+               size_t length = (end_sample - start_sample) * unit_size;
 
                try {
                        const auto context = session_.device_manager().context();