diff options
author | iphydf <iphydf@users.noreply.github.com> | 2016-09-01 18:49:49 +0100 |
---|---|---|
committer | iphydf <iphydf@users.noreply.github.com> | 2016-09-01 18:49:49 +0100 |
commit | 579bdc126f3054e27224b2b612eea52eb22e8507 (patch) | |
tree | 4d61375c0318016cc569682b1f1df5a5eb40dcfd | |
parent | 77db27331eb326615395fa59f3741424f85887bb (diff) |
Remove useless casts.
These casts are either completely useless (casting T to T) or implicit (x = y).
-rw-r--r-- | toxav/video.c | 2 | ||||
-rw-r--r-- | toxcore/assoc.c | 2 | ||||
-rw-r--r-- | toxcore/onion_announce.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/toxav/video.c b/toxav/video.c index 7eba21cf..195ff041 100644 --- a/toxav/video.c +++ b/toxav/video.c | |||
@@ -128,7 +128,7 @@ void vc_kill(VCSession *vc) | |||
128 | 128 | ||
129 | void *p; | 129 | void *p; |
130 | 130 | ||
131 | while (rb_read(vc->vbuf_raw, (void **)&p)) { | 131 | while (rb_read(vc->vbuf_raw, &p)) { |
132 | free(p); | 132 | free(p); |
133 | } | 133 | } |
134 | 134 | ||
diff --git a/toxcore/assoc.c b/toxcore/assoc.c index 3a033851..ced1f65a 100644 --- a/toxcore/assoc.c +++ b/toxcore/assoc.c | |||
@@ -891,7 +891,7 @@ Assoc *new_Assoc(Logger *log, size_t bits, size_t entries, const uint8_t *public | |||
891 | if (entries_test != entries) { | 891 | if (entries_test != entries) { |
892 | 892 | ||
893 | LOGGER_DEBUG(assoc->log, "trimmed %i to %i.\n", (int)entries, (int)entries_test); | 893 | LOGGER_DEBUG(assoc->log, "trimmed %i to %i.\n", (int)entries, (int)entries_test); |
894 | entries = (size_t)entries_test; | 894 | entries = entries_test; |
895 | } | 895 | } |
896 | } | 896 | } |
897 | 897 | ||
diff --git a/toxcore/onion_announce.c b/toxcore/onion_announce.c index cebd56bb..3be76ddf 100644 --- a/toxcore/onion_announce.c +++ b/toxcore/onion_announce.c | |||
@@ -95,7 +95,7 @@ int create_data_request(uint8_t *packet, uint16_t max_packet_length, const uint8 | |||
95 | return -1; | 95 | return -1; |
96 | } | 96 | } |
97 | 97 | ||
98 | if ((unsigned int)DATA_REQUEST_MIN_SIZE + length > ONION_MAX_DATA_SIZE) { | 98 | if (DATA_REQUEST_MIN_SIZE + length > ONION_MAX_DATA_SIZE) { |
99 | return -1; | 99 | return -1; |
100 | } | 100 | } |
101 | 101 | ||