summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/server/net.c2
-rw-r--r--src/shared/protocol.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/server/net.c b/src/server/net.c
index 864d260..dcdbaea 100644
--- a/src/server/net.c
+++ b/src/server/net.c
@@ -239,7 +239,7 @@ void* net_handleNewConnection(void *clientPtr)
if ( !client->isServer || !_isProxy ) {
// Is a normal client, or we're not proxy
image = image_getOrLoad( image_name, rid );
- } else if ( !_backgroundReplication && ( flags & FLAGS8_BG_REP ) ) {
+ } else if ( _backgroundReplication != BGR_FULL && ( flags & FLAGS8_BG_REP ) ) {
// We're a proxy, client is another proxy, we don't do BGR, but connecting proxy does...
// Reject, as this would basically force this proxy to do BGR too.
image = image_get( image_name, rid, true );
diff --git a/src/shared/protocol.h b/src/shared/protocol.h
index 6f1cca6..d87bbd8 100644
--- a/src/shared/protocol.h
+++ b/src/shared/protocol.h
@@ -20,7 +20,7 @@
#define COND_HOPCOUNT(vers,hopcount) ( (vers) >= 3 ? (hopcount) : 0 )
// 2017-11-02: Macro to set flags in select image message properly if we're a server, as BG_REP depends on global var
-#define SI_SERVER_FLAGS ( FLAGS8_SERVER | (_backgroundReplication ? FLAGS8_BG_REP : 0) )
+#define SI_SERVER_FLAGS ( FLAGS8_SERVER | (_backgroundReplication == BGR_FULL ? FLAGS8_BG_REP : 0) )
#define REPLY_OK (0)
#define REPLY_ERRNO (-1)