From 52d02fda9bad1a0ffe9b03b819e64ae1af4787db Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Tue, 8 May 2018 12:50:46 +0200 Subject: [PATCH] cosmetics: use explicitly 'not' instead of a raw ! --- examples/msg/dht-pastry/dht-pastry.c | 5 ++--- teshsuite/msg/app-bittorrent/bittorrent-peer.c | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/examples/msg/dht-pastry/dht-pastry.c b/examples/msg/dht-pastry/dht-pastry.c index e4e48097f3..0cf0155b06 100644 --- a/examples/msg/dht-pastry/dht-pastry.c +++ b/examples/msg/dht-pastry/dht-pastry.c @@ -1,5 +1,4 @@ -/* Copyright (c) 2013-2018. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2013-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -313,7 +312,7 @@ static void handle_task(node_t node, msg_task_t task) { // if the node is ready, do all the pending tasks and send update to known nodes if (node->ready==0) { XBT_DEBUG("Node %i is ready!!!", node->id); - while (!xbt_dynar_is_empty(node->pending_tasks)) { + while (not xbt_dynar_is_empty(node->pending_tasks)) { msg_task_t task; xbt_dynar_shift(node->pending_tasks, &task); handle_task(node, task); diff --git a/teshsuite/msg/app-bittorrent/bittorrent-peer.c b/teshsuite/msg/app-bittorrent/bittorrent-peer.c index 700d920c3a..69818a5ead 100644 --- a/teshsuite/msg/app-bittorrent/bittorrent-peer.c +++ b/teshsuite/msg/app-bittorrent/bittorrent-peer.c @@ -591,7 +591,7 @@ void update_choked_peers(peer_t peer) // remove a peer from the list xbt_dict_cursor_t cursor = NULL; xbt_dict_cursor_first(peer->active_peers, &cursor); - if (!xbt_dict_is_empty(peer->active_peers)) { + if (not xbt_dict_is_empty(peer->active_peers)) { key_choked = xbt_dict_cursor_get_key(cursor); peer_choked = xbt_dict_cursor_get_data(cursor); } -- 2.20.1