forked from Kistler-Group/sdbus-cpp
Compare commits
2 Commits
feature/ad
...
fix_deprec
Author | SHA1 | Date | |
---|---|---|---|
e199dc58cf | |||
ad7731d900 |
@ -25,7 +25,7 @@ public:
|
||||
|
||||
if (poll_data.timeout_usec != UINT64_MAX) {
|
||||
timer_.async_wait([this](boost::system::error_code const&) { processTimeout(); });
|
||||
timer_.expires_from_now(boost::posix_time::microsec(poll_data.timeout_usec));
|
||||
timer_.expires_after(boost::posix_time::microsec(poll_data.timeout_usec));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -292,12 +292,12 @@ void Document::Expat::character_data_handler(void* data, const XML_Char* chars,
|
||||
nod = &(nod->children.back());
|
||||
}
|
||||
|
||||
int x = 0, y = len - 1;
|
||||
int offset = 0, count = len;
|
||||
|
||||
while (isspace(chars[y]) && y > 0) --y;
|
||||
while (isspace(chars[x]) && x < y) ++x;
|
||||
while (count > 0 && isspace(chars[count - 1])) --count;
|
||||
while (offset < count && isspace(chars[offset])) { ++offset; --count; }
|
||||
|
||||
nod->cdata = std::string(chars, x, y + 1);
|
||||
nod->cdata = std::string{chars + offset, static_cast<std::string::size_type>(count)};
|
||||
}
|
||||
|
||||
void Document::Expat::end_element_handler(void* data, const XML_Char* /*name*/)
|
||||
|
Reference in New Issue
Block a user