diff options
author | Christian Grothoff <christian@grothoff.org> | 2012-09-28 22:14:56 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2012-09-28 22:14:56 +0000 |
commit | 1ca51e5871f9b471425f9c88c358cb963a68aaed (patch) | |
tree | 371827123852b7df837433b4aab69c1374e36d5a /src/gns | |
parent | 44acea91cdc4d6468154bf5a6f1755e5622d9eb6 (diff) | |
download | gnunet-1ca51e5871f9b471425f9c88c358cb963a68aaed.tar.gz gnunet-1ca51e5871f9b471425f9c88c358cb963a68aaed.zip |
-dce, stylistic fixes
Diffstat (limited to 'src/gns')
-rw-r--r-- | src/gns/gnunet-gns-proxy.c | 6 | ||||
-rw-r--r-- | src/gns/gnunet-service-gns_resolver.c | 6 |
2 files changed, 4 insertions, 8 deletions
diff --git a/src/gns/gnunet-gns-proxy.c b/src/gns/gnunet-gns-proxy.c index 7fe221b7c..ad8b95915 100644 --- a/src/gns/gnunet-gns-proxy.c +++ b/src/gns/gnunet-gns-proxy.c | |||
@@ -1189,11 +1189,7 @@ mhd_content_cb (void *cls, | |||
1189 | } | 1189 | } |
1190 | 1190 | ||
1191 | if (bytes_to_copy + copied > max) | 1191 | if (bytes_to_copy + copied > max) |
1192 | bytes_to_copy = max-copied; | 1192 | bytes_to_copy = max - copied; |
1193 | |||
1194 | if (0 > bytes_to_copy) | ||
1195 | bytes_to_copy = 0; | ||
1196 | |||
1197 | memcpy (buf+copied, ctask->buffer_read_ptr, bytes_to_copy); | 1193 | memcpy (buf+copied, ctask->buffer_read_ptr, bytes_to_copy); |
1198 | ctask->buffer_read_ptr += bytes_to_copy; | 1194 | ctask->buffer_read_ptr += bytes_to_copy; |
1199 | copied += bytes_to_copy; | 1195 | copied += bytes_to_copy; |
diff --git a/src/gns/gnunet-service-gns_resolver.c b/src/gns/gnunet-service-gns_resolver.c index 11ea5a993..0729d6674 100644 --- a/src/gns/gnunet-service-gns_resolver.c +++ b/src/gns/gnunet-service-gns_resolver.c | |||
@@ -3622,7 +3622,7 @@ process_zone_to_name_shorten_shorten (void *cls, | |||
3622 | * No PSEU found. | 3622 | * No PSEU found. |
3623 | * continue with next authority if exists | 3623 | * continue with next authority if exists |
3624 | */ | 3624 | */ |
3625 | if ((rh->authority_chain_head->next == NULL)) | 3625 | if (NULL == rh->authority_chain_head->next) |
3626 | { | 3626 | { |
3627 | finish_shorten (rh, nsh); | 3627 | finish_shorten (rh, nsh); |
3628 | return; | 3628 | return; |
@@ -3735,7 +3735,7 @@ process_zone_to_name_shorten_private (void *cls, | |||
3735 | * No PSEU found. | 3735 | * No PSEU found. |
3736 | * continue with next authority if exists | 3736 | * continue with next authority if exists |
3737 | */ | 3737 | */ |
3738 | if ((rh->authority_chain_head->next == NULL)) | 3738 | if (NULL == rh->authority_chain_head->next) |
3739 | { | 3739 | { |
3740 | finish_shorten (rh, nsh); | 3740 | finish_shorten (rh, nsh); |
3741 | return; | 3741 | return; |
@@ -3857,7 +3857,7 @@ process_zone_to_name_shorten_root (void *cls, | |||
3857 | * No PSEU found. | 3857 | * No PSEU found. |
3858 | * continue with next authority if exists | 3858 | * continue with next authority if exists |
3859 | */ | 3859 | */ |
3860 | if ((rh->authority_chain_head->next == NULL)) | 3860 | if (NULL == rh->authority_chain_head->next) |
3861 | { | 3861 | { |
3862 | finish_shorten (rh, nsh); | 3862 | finish_shorten (rh, nsh); |
3863 | return; | 3863 | return; |