Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 18, 2009, 4:03:59 PM (16 years ago)
Author:
rgrieder
Message:

Found even more casts. They sure aren't all of them, but I hope to have caught every pointer C-style cast because they can be very dangerous.
Note: I didn't do the pointer casts in the network library because that would have taken way too long.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/core/Shell.cc

    r3300 r3301  
    228228    std::string Shell::getFromHistory() const
    229229    {
    230         unsigned int index = mod(((int)this->historyOffset_) - ((int)this->historyPosition_), this->maxHistoryLength_);
     230        unsigned int index = mod(static_cast<int>(this->historyOffset_) - static_cast<int>(this->historyPosition_), this->maxHistoryLength_);
    231231        if (index < this->commandHistory_.size() && this->historyPosition_ != 0)
    232232            return this->commandHistory_[index];
     
    249249            {
    250250                if (this->bAddOutputLevel_)
    251                     output.insert(0, 1, (char)OutputHandler::getOutStream().getOutputLevel());
     251                    output.insert(0, 1, static_cast<char>(OutputHandler::getOutStream().getOutputLevel()));
    252252
    253253                this->lines_.insert(this->lines_.begin(), output);
Note: See TracChangeset for help on using the changeset viewer.