From d7faa0de0b53b3a2986d21893d65265936656339 Mon Sep 17 00:00:00 2001 From: Willem Jan Withagen Date: Mon, 22 Oct 2018 21:42:30 +0200 Subject: [PATCH] common: Fix function const, when not all serial() are const. And then Clang complains: ``` /home/jenkins/workspace/ceph-master/src/common/blkdev.cc:700:13: error: out-of-line definition of 'serial' does not match any declaration in 'Bl kDev' int BlkDev::serial(char *serial, size_t max) ^~~~~~ /home/jenkins/workspace/ceph-master/src/common/blkdev.h:50:7: note: member declaration does not match because it is const qualified int serial(char *serial, size_t max) const; ^ ~~~~~ 1 error generated. ``` Signed-off-by: Willem Jan Withagen --- src/common/blkdev.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/blkdev.cc b/src/common/blkdev.cc index 6ff18634bed..8ddffda55f0 100644 --- a/src/common/blkdev.cc +++ b/src/common/blkdev.cc @@ -697,7 +697,7 @@ int BlkDev::model(char *model, size_t max) const return 0; } -int BlkDev::serial(char *serial, size_t max) +int BlkDev::serial(char *serial, size_t max) const { char ident[DISK_IDENT_SIZE]; -- 2.39.5