]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
mgr: fix Clang warning on superfluous brackets
authorWillem Jan Withagen <wjw@digiware.nl>
Sun, 25 Nov 2018 14:44:06 +0000 (15:44 +0100)
committerWillem Jan Withagen <wjw@digiware.nl>
Sun, 25 Nov 2018 15:18:16 +0000 (16:18 +0100)
```
/home/jenkins/workspace/ceph-master/src/mgr/OSDPerfMetricTypes.h:105:19: warning: braces around scalar initializer [-Wbraced-scalar-init]
        d.regex = {d.regex_str.c_str()};
                  ^~~~~~~~~~~~~~~~~~~~~
1 warning generated.
```

Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
src/mgr/OSDPerfMetricTypes.h

index 38bbd2c69d14424ba4178d5880c48b3039776afc..c3d281e235a368e220e3d971693bf87ab0325084 100644 (file)
@@ -102,7 +102,7 @@ struct denc_traits<OSDPerfMetricKeyDescriptor> {
         return;
       }
       try {
-        d.regex = {d.regex_str.c_str()};
+        d.regex = d.regex_str.c_str();
       } catch (const std::regex_error& e) {
         v.clear();
         return;