Skip to contentSkip to conversation

nbd: Fix trace message for disconnect

PATCH In review Eric Blake 2 participants 2 messages Aug 11, 2017

lore
Share & tools
lore

Eric Blake

author
#0 lore raw

PATCH 1/1 nbd: Fix trace message for disconnect

NBD_CMD_DISC is a disconnect request, not a data discard request.

---

Although this is not 2.10 material in isolation (it is only a bad trace message), I don't mind including it in a larger pull request; I'm still planning to fix the issue of a client hanging on a malicious server in time for -rc3 (whether via Vladimir's patch or a smaller one that I'm testing locally).

 nbd/common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
nbd/common.c +1 -1
index a2f28f2eec..e288d1b972 100644
@@ -182,7 +182,7 @@ const char *nbd_cmd_lookup(uint16_t cmd)
     case NBD_CMD_WRITE:
         return "write";
     case NBD_CMD_DISC:
-        return "discard";
+        return "disconnect";
     case NBD_CMD_FLUSH:
         return "flush";
     case NBD_CMD_TRIM:
Signature · 1 line
2.13.4
Reviewed-by on v1 1/1
#1 lore raw
Quoted 5 lines · Eric Blake

NBD_CMD_DISC is a disconnect request, not a data discard request.

---

Quoted 8 lines

Although this is not 2.10 material in isolation (it is only a bad trace message), I don't mind including it in a larger pull request; I'm still planning to fix the issue of a client hanging on a malicious server in time for -rc3 (whether via Vladimir's patch or a smaller one that I'm testing locally).

 nbd/common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)