diff options
author | smatz <smatz@openttd.org> | 2008-06-01 15:08:14 +0000 |
---|---|---|
committer | smatz <smatz@openttd.org> | 2008-06-01 15:08:14 +0000 |
commit | ed462507b26229732ebe45ea0a2583809ff90ee8 (patch) | |
tree | a69876051417b114e25b34280ada013d1522cee1 /src/driver.cpp | |
parent | 10d6f6c5b841f8fb161a4715c74a043c11a70107 (diff) | |
download | openttd-ed462507b26229732ebe45ea0a2583809ff90ee8.tar.xz |
(svn r13351) -Codechange: disable warnings about unused variable for builds without asserts
Diffstat (limited to 'src/driver.cpp')
-rw-r--r-- | src/driver.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/driver.cpp b/src/driver.cpp index a71f21cc7..202b84fab 100644 --- a/src/driver.cpp +++ b/src/driver.cpp @@ -156,11 +156,7 @@ void DriverFactoryBase::RegisterDriver(const char *name, Driver::Type type, int strecpy(buf, GetDriverTypeName(type), lastof(buf)); strecpy(buf + 5, name, lastof(buf)); -#if !defined(NDEBUG) || defined(WITH_ASSERT) - /* NDEBUG disables asserts and gives a warning: unused variable 'P' */ - std::pair<Drivers::iterator, bool> P = -#endif /* !NDEBUG */ - GetDrivers().insert(Drivers::value_type(buf, this)); + std::pair<Drivers::iterator, bool> P = GetDrivers().insert(Drivers::value_type(buf, this)); assert(P.second); } |