summaryrefslogtreecommitdiff
path: root/delayed-ref.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2018-11-13 13:28:09 +0100
committerDavid Sterba <dsterba@suse.com>2018-11-13 13:33:15 +0100
commitd96671ae54ca1f9cbc47ac4494421b7af7a5cf65 (patch)
tree60882bf9c27e81a811057c64a739eacd7e779727 /delayed-ref.c
parent01e35d9f53ebee57ccf5c46aadd809c9ecb9c802 (diff)
btrfs-progs: kerncompat: rename swap to __swap
The 'swap' is too generic and clashes with some userspace tools that compile against btrfs, eg. snapper when including boost::smart_ptr::scoped_array after kerncompat.h: /usr/include/boost/smart_ptr/scoped_array.hpp:127:13: error: macro "swap" requires 2 arguments, but only 1 given a.swap(b); Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'delayed-ref.c')
-rw-r--r--delayed-ref.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/delayed-ref.c b/delayed-ref.c
index e8123436..9974dbbd 100644
--- a/delayed-ref.c
+++ b/delayed-ref.c
@@ -201,7 +201,7 @@ static bool merge_ref(struct btrfs_trans_handle *trans,
mod = next->ref_mod;
} else {
if (ref->ref_mod < next->ref_mod) {
- swap(ref, next);
+ __swap(ref, next);
done = true;
}
mod = -next->ref_mod;