mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:47:44 +00:00
AK: Remove unnecessary casts to size_t, after Vector changes
Now that Vector uses size_t, we can remove a whole bunch of redundant casts to size_t.
This commit is contained in:
parent
fee20bd8de
commit
22d0a6d92f
15 changed files with 60 additions and 57 deletions
|
@ -108,7 +108,7 @@ public:
|
|||
|
||||
auto buffer = message.encode();
|
||||
|
||||
int nwritten = write(m_socket->fd(), buffer.data(), (size_t)buffer.size());
|
||||
int nwritten = write(m_socket->fd(), buffer.data(), buffer.size());
|
||||
if (nwritten < 0) {
|
||||
switch (errno) {
|
||||
case EPIPE:
|
||||
|
@ -149,7 +149,7 @@ public:
|
|||
}
|
||||
|
||||
size_t decoded_bytes = 0;
|
||||
for (size_t index = 0; index < (size_t)bytes.size(); index += decoded_bytes) {
|
||||
for (size_t index = 0; index < bytes.size(); index += decoded_bytes) {
|
||||
auto remaining_bytes = ByteBuffer::wrap(bytes.data() + index, bytes.size() - index);
|
||||
auto message = Endpoint::decode_message(remaining_bytes, decoded_bytes);
|
||||
if (!message) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue