Don't increment an iterator if it's past the end

Found by coverity
This commit is contained in:
Alexander van Gessel 2013-12-08 03:58:05 +01:00
parent c217ce7a12
commit 9a0512772e

View file

@ -482,10 +482,10 @@ theme::status_item::status_item(const config& cfg) :
++c;
if(c != rgb_vec.end()){
g = (atoi(c->c_str()));
++c;
}else{
g=0;
}
++c;
if(c != rgb_vec.end()){
b=(atoi(c->c_str()));
}else{