You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
49 lines
1.4 KiB
49 lines
1.4 KiB
From f62b558e1a7403b4a17ed0141c0a799990f27932 Mon Sep 17 00:00:00 2001 |
|
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com> |
|
Date: Mon, 12 Aug 2019 13:30:43 +0200 |
|
Subject: [PATCH] Correct indentation |
|
MIME-Version: 1.0 |
|
Content-Type: text/plain; charset=UTF-8 |
|
Content-Transfer-Encoding: 8bit |
|
|
|
GCC 9.1.1 complains: |
|
|
|
../SFconv/SFconv.cpp:104:5: warning: this 'while' clause does not guard... [-Wmisleading-indentation] |
|
104 | while (in != end && !(in.error() || out.error())) |
|
| ^~~~~ |
|
../SFconv/SFconv.cpp:107:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'while' |
|
107 | if (in.error() || out.error()) { |
|
| ^~ |
|
|
|
This patch fixes it. |
|
|
|
Signed-off-by: Petr Písař <ppisar@redhat.com> |
|
--- |
|
SFconv/SFconv.cpp | 4 ++-- |
|
1 file changed, 2 insertions(+), 2 deletions(-) |
|
|
|
diff --git a/SFconv/SFconv.cpp b/SFconv/SFconv.cpp |
|
index eeb4490..df6f8a4 100644 |
|
--- a/SFconv/SFconv.cpp |
|
+++ b/SFconv/SFconv.cpp |
|
@@ -101,7 +101,7 @@ Utf8ToString(const char* s) |
|
utf16::iterator out = buf; |
|
utf8::const_iterator in = s, |
|
end = s + len; |
|
- while (in != end && !(in.error() || out.error())) |
|
+ while (in != end && !(in.error() || out.error())) |
|
*out++ = *in++; |
|
|
|
if (in.error() || out.error()) { |
|
@@ -109,7 +109,7 @@ Utf8ToString(const char* s) |
|
exit(1); |
|
} |
|
|
|
- ustring ustr(buf, out - buf); |
|
+ ustring ustr(buf, out - buf); |
|
delete[] buf; |
|
return ustr; |
|
} |
|
-- |
|
2.21.0 |
|
|
|
|