From 4908079c20a3adedf32e728f603494a1e536c710 Mon Sep 17 00:00:00 2001 From: Danny Al-Gaaf Date: Fri, 10 May 2013 13:44:50 +0200 Subject: [PATCH] rados_sync.cc: remove dead and not needed code The first if handles all chars < 32, the last 2 if's check for '\n' (10) and '\r' (13). This code will never be reached and is already covered. Remove unneeded code. CID 1019549 Logically dead code (CWE-561) Signed-off-by: Danny Al-Gaaf --- src/rados_sync.cc | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/rados_sync.cc b/src/rados_sync.cc index 5d4bae198f660..c55e5b21bea19 100644 --- a/src/rados_sync.cc +++ b/src/rados_sync.cc @@ -185,14 +185,6 @@ std::string ExportDir::get_fs_path(const std::string &rados_name) const c = '_'; need_hash = true; } - else if (c == '\n') { - c = '@'; - need_hash = true; - } - else if (c == '\r') { - c = '@'; - need_hash = true; - } fs_path[i] = c; } -- 2.39.5