]> git.tdb.fi Git - r2c2.git/commitdiff
Some variable cleanup
authorMikko Rasa <tdb@tdb.fi>
Wed, 30 Oct 2013 22:24:08 +0000 (00:24 +0200)
committerMikko Rasa <tdb@tdb.fi>
Wed, 30 Oct 2013 22:24:08 +0000 (00:24 +0200)
source/libr2c2/blockallocator.cpp
source/libr2c2/layout.cpp
source/libr2c2/layout.h

index 674722bb9d21b6951bd0f8b0405fad8e4ecd4db3..e28558a7e0cd9e715e32722900dae39e544729b3 100644 (file)
@@ -28,6 +28,7 @@ struct BlockAllocator::BlockMatch
 
 BlockAllocator::BlockAllocator(Train &t):
        train(t),
+       active(false),
        cur_blocks_end(blocks.end()),
        next_sensor(0),
        pending_block(0),
index 598bf82bcf4c0a1763a22d9b78562b21c4d6e00e..c2de1c599a08712ec1893602e527d96972d2a246 100644 (file)
@@ -528,8 +528,7 @@ void Layout::Storage<B>::del()
 
 
 Layout::Loader::Loader(Layout &l):
-       DataFile::ObjectLoader<Layout>(l),
-       new_tracks(false)
+       DataFile::ObjectLoader<Layout>(l)
 {
        add("base",  &Layout::base);
        add("beamgate", &Loader::beamgate);
@@ -563,7 +562,6 @@ void Layout::Loader::track(ArticleNumber art_nr)
 {
        Track *trk = new Track(obj, obj.catalogue.get<TrackType>(art_nr));
        load_sub(*trk);
-       new_tracks = true;
        const set<Track *> &tracks = obj.objects.get<Track>();
        for(set<Track *>::const_iterator i=tracks.begin(); i!=tracks.end(); ++i)
                if(*i!=trk)
index 26df423ed731b3f461f912ee04b4c57e19fde08e..59eae083d05253b6d8c7d5a5e80ad0498d136c94 100644 (file)
@@ -30,9 +30,6 @@ class Layout
 public:
        class Loader: public Msp::DataFile::ObjectLoader<Layout>
        {
-       private:
-               bool new_tracks;
-
        public:
                Loader(Layout &);
        private: