Author: dmacvicar Date: Tue Jun 19 22:50:43 2007 New Revision: 5799 URL: http://svn.opensuse.org/viewcvs/zypp?rev=5799&view=rev Log: - throw repounknowntype except on string parsing. Modified: trunk/libzypp/zypp/repo/RepoException.h trunk/libzypp/zypp/repo/RepoType.cc Modified: trunk/libzypp/zypp/repo/RepoException.h URL: http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/repo/RepoException.h?rev=5799&r1=5798&r2=5799&view=diff ============================================================================== --- trunk/libzypp/zypp/repo/RepoException.h (original) +++ trunk/libzypp/zypp/repo/RepoException.h Tue Jun 19 22:50:43 2007 @@ -122,7 +122,16 @@ */ class RepoUnknownTypeException : public RepoException { - + public: + RepoUnknownTypeException( const std::string & msg_r ) + : RepoException(msg_r) + {} + + RepoUnknownTypeException() + {} + + ~RepoUnknownTypeException() throw() + {} }; ///////////////////////////////////////////////////////////////// Modified: trunk/libzypp/zypp/repo/RepoType.cc URL: http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/repo/RepoType.cc?rev=5799&r1=5798&r2=5799&view=diff ============================================================================== --- trunk/libzypp/zypp/repo/RepoType.cc (original) +++ trunk/libzypp/zypp/repo/RepoType.cc Tue Jun 19 22:50:43 2007 @@ -9,7 +9,7 @@ #include <iostream> #include <map> -#include "zypp/base/Exception.h" +#include "zypp/repo/RepoException.h" #include "RepoType.h" namespace zypp @@ -46,8 +46,8 @@ = _table.find(strval_r); if (it == _table.end()) { - ZYPP_THROW(Exception( - "RepoType parse: illegal string value '" + strval_r + "'")); + ZYPP_THROW(RepoUnknownTypeException( + "Unknown repository type '" + strval_r + "'")); } return it->second; } -- To unsubscribe, e-mail: zypp-commit+unsubscribe@opensuse.org For additional commands, e-mail: zypp-commit+help@opensuse.org