[gnutls-devel] [PATCH 5/6] Removed reduntant condition in _gnutls_buffer_append_data().
Jaak Ristioja
jaak.ristioja at cyber.ee
Tue Dec 16 17:18:38 CET 2014
The above definition of variable unused implies that it should be non-NULL.
---
lib/gnutls_str.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/gnutls_str.c b/lib/gnutls_str.c
index 3cc7f7e..29eb95e 100644
--- a/lib/gnutls_str.c
+++ b/lib/gnutls_str.c
@@ -117,7 +117,7 @@ _gnutls_buffer_append_data(gnutls_buffer_st * dest, const void *data,
size_t const tot_len = data_size + dest->length;
if (dest->max_length >= tot_len) {
if (dest->max_length - unused <= tot_len) {
- if (dest->length && dest->data)
+ if (dest->length)
memmove(dest->allocd, dest->data,
dest->length);
--
2.2.0
More information about the Gnutls-devel
mailing list