X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibr2c2%2Froute.cpp;fp=source%2Flibr2c2%2Froute.cpp;h=820ce1e32dad1536cce73ec313edfe70de9780f2;hb=621c5c938d70ba0d155e0eda91a708db0a52c0dc;hp=aabe8807b71cd4b7d92927ca6427edce21f804d1;hpb=9bab44d27a89602565270e71d8684fb3f2fac5be;p=r2c2.git diff --git a/source/libr2c2/route.cpp b/source/libr2c2/route.cpp index aabe880..820ce1e 100644 --- a/source/libr2c2/route.cpp +++ b/source/libr2c2/route.cpp @@ -169,10 +169,10 @@ void Route::set_temporary(bool t) void Route::set_turnout(unsigned addr, unsigned path) { if(!addr) - throw InvalidParameterValue("Invalid turnout address"); + throw invalid_argument("Route::set_turnout"); int &state = get_item(turnouts, addr); if(state>=0 && path!=static_cast(state)) - throw InvalidState("Setting conflicts with route"); + throw logic_error("route conflict"); state = path; }