[med-svn] [aghermann] 25/31: thank you valgrind

andrei zavada hmmr-guest at alioth.debian.org
Sun Nov 10 00:34:19 UTC 2013


This is an automated email from the git hooks/post-receive script.

hmmr-guest pushed a commit to branch WIP
in repository aghermann.

commit 87c08ef6a78128f73a5b9b29dec936cc883da7cf
Author: Andrei Zavada <hmmr at ra>
Date:   Sun Nov 10 01:51:55 2013 +0200

    thank you valgrind
---
 upstream/src/aghermann/expdesign/recording.cc          |    6 +++---
 upstream/src/aghermann/ui/dirlevel-storable-adapter.ii |    5 +++--
 upstream/src/aghermann/ui/sf/channel.cc                |    2 +-
 3 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/upstream/src/aghermann/expdesign/recording.cc b/upstream/src/aghermann/expdesign/recording.cc
index d46e83d..e68f4d2 100644
--- a/upstream/src/aghermann/expdesign/recording.cc
+++ b/upstream/src/aghermann/expdesign/recording.cc
@@ -263,10 +263,10 @@ create_timeline()
 
               // collect M's power and scores
                 valarray<TFloat>
-                        lumped_bins = M.course( *(SProfileParamSet*)this);
+                        lumped_bins {M.course( *(SProfileParamSet*)this)};
 
-                size_t        pa = (size_t)difftime( F.start_time(), _0at) / _pagesize,
-                        pz = (size_t)difftime( F.end_time(), _0at) / _pagesize;
+                size_t  pa = (size_t)difftime( F.start_time(), _0at) / _pagesize,
+                        pz = pa + lumped_bins.size(); // (size_t)difftime( F.end_time(), _0at) / _pagesize;
                 for ( size_t p = pa; p < pz; ++p ) {
                         _timeline[p] = sigfile::SPageSimulated {Y[p-pa]};
                       // fill unscored/MVT per user setting
diff --git a/upstream/src/aghermann/ui/dirlevel-storable-adapter.ii b/upstream/src/aghermann/ui/dirlevel-storable-adapter.ii
index 23df6e8..817cec3 100644
--- a/upstream/src/aghermann/ui/dirlevel-storable-adapter.ii
+++ b/upstream/src/aghermann/ui/dirlevel-storable-adapter.ii
@@ -90,6 +90,7 @@ populate_combo()
 
         if ( not profiles.empty() ) {
                 GtkTreeIter iter, current_profile_iter;
+                bool iter_set = false;
                 for ( auto I = profiles.begin(); I != profiles.end(); ++I ) {
                         gtk_list_store_append(
                                 mXProfiles, &iter);
@@ -98,10 +99,10 @@ populate_combo()
                                 0, snprintf_buf( "%s %s", agh::exp_dir_level_s(I->level), I->name.c_str()),
                                 -1);
                         if ( I == current_profile )
-                                current_profile_iter = iter;
+                                iter_set = true, current_profile_iter = iter;
                 }
 
-                gtk_combo_box_set_active_iter( eXProfileList, &current_profile_iter);
+                gtk_combo_box_set_active_iter( eXProfileList, iter_set ? &current_profile_iter : NULL);
         } else
                 gtk_combo_box_set_active_iter( eXProfileList, NULL);
 
diff --git a/upstream/src/aghermann/ui/sf/channel.cc b/upstream/src/aghermann/ui/sf/channel.cc
index 6f3be71..5e9be74 100644
--- a/upstream/src/aghermann/ui/sf/channel.cc
+++ b/upstream/src/aghermann/ui/sf/channel.cc
@@ -64,7 +64,7 @@ SChannel (agh::CRecording& r,
         draw_psd_bands          (true),
         draw_spectrum           (true),
         resample_signal         (true),
-        // resample_power       (true), // set based on pages-per-pixel
+        resample_power          (true),
         draw_selection_course   (false),
         draw_selection_envelope (true),
         draw_selection_dzcdf    (false),

-- 
Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/aghermann.git



More information about the debian-med-commit mailing list