Merge bugfix #607
authorAlpar Juttner <alpar@cs.elte.hu>
Tue, 19 Sep 2017 15:23:43 +0200
changeset 1376bc571f16e1e9
parent 1371 0898f3371d1d
parent 1373 332627dd249e
child 1377 7d32a2d6ed59
child 1405 3feba0ea1bda
Merge bugfix #607
lemon/dimacs.h
     1.1 --- a/lemon/dimacs.h	Fri Jan 27 20:35:13 2017 +0100
     1.2 +++ b/lemon/dimacs.h	Tue Sep 19 15:23:43 2017 +0200
     1.3 @@ -25,6 +25,7 @@
     1.4  #include <limits>
     1.5  #include <lemon/maps.h>
     1.6  #include <lemon/error.h>
     1.7 +
     1.8  /// \ingroup dimacs_group
     1.9  /// \file
    1.10  /// \brief DIMACS file format reader.
    1.11 @@ -122,7 +123,7 @@
    1.12    /// a non-zero value, that value will be used as "infinite".
    1.13    ///
    1.14    /// If the file type was previously evaluated by dimacsType(), then
    1.15 -  /// the descriptor struct should be given by the \c dest parameter.
    1.16 +  /// the descriptor struct should be given by the \c desc parameter.
    1.17    template <typename Digraph, typename LowerMap,
    1.18              typename CapacityMap, typename CostMap,
    1.19              typename SupplyMap>
    1.20 @@ -276,7 +277,7 @@
    1.21    /// a non-zero value, that value will be used as "infinite".
    1.22    ///
    1.23    /// If the file type was previously evaluated by dimacsType(), then
    1.24 -  /// the descriptor struct should be given by the \c dest parameter.
    1.25 +  /// the descriptor struct should be given by the \c desc parameter.
    1.26    template<typename Digraph, typename CapacityMap>
    1.27    void readDimacsMax(std::istream& is,
    1.28                       Digraph &g,
    1.29 @@ -303,7 +304,7 @@
    1.30    /// source node.
    1.31    ///
    1.32    /// If the file type was previously evaluated by dimacsType(), then
    1.33 -  /// the descriptor struct should be given by the \c dest parameter.
    1.34 +  /// the descriptor struct should be given by the \c desc parameter.
    1.35    template<typename Digraph, typename LengthMap>
    1.36    void readDimacsSp(std::istream& is,
    1.37                      Digraph &g,
    1.38 @@ -334,7 +335,7 @@
    1.39    /// a non-zero value, that value will be used as "infinite".
    1.40    ///
    1.41    /// If the file type was previously evaluated by dimacsType(), then
    1.42 -  /// the descriptor struct should be given by the \c dest parameter.
    1.43 +  /// the descriptor struct should be given by the \c desc parameter.
    1.44    template<typename Digraph, typename CapacityMap>
    1.45    void readDimacsCap(std::istream& is,
    1.46                       Digraph &g,
    1.47 @@ -343,7 +344,7 @@
    1.48                       DimacsDescriptor desc=DimacsDescriptor()) {
    1.49      typename Digraph::Node u,v;
    1.50      if(desc.type==DimacsDescriptor::NONE) desc=dimacsType(is);
    1.51 -    if(desc.type!=DimacsDescriptor::MAX || desc.type!=DimacsDescriptor::SP)
    1.52 +    if(desc.type!=DimacsDescriptor::MAX && desc.type!=DimacsDescriptor::SP)
    1.53        throw FormatError("Problem type mismatch");
    1.54      _readDimacs(is, g, capacity, u, v, infty, desc);
    1.55    }
    1.56 @@ -374,7 +375,7 @@
    1.57    /// At the beginning, \c g is cleared by \c g.clear().
    1.58    ///
    1.59    /// If the file type was previously evaluated by dimacsType(), then
    1.60 -  /// the descriptor struct should be given by the \c dest parameter.
    1.61 +  /// the descriptor struct should be given by the \c desc parameter.
    1.62    template<typename Graph>
    1.63    void readDimacsMat(std::istream& is, Graph &g,
    1.64                       DimacsDescriptor desc=DimacsDescriptor())