Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(289)

Unified Diff: fusl/src/string/wcsncasecmp.c

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: fusl/src/string/wcsncasecmp.c
diff --git a/fusl/src/string/wcsncasecmp.c b/fusl/src/string/wcsncasecmp.c
index 8fefe799c4370312f7539cc7a2e24016d9b7f546..a756c2e5192c022c5bc5d422e747af3cd1d16be3 100644
--- a/fusl/src/string/wcsncasecmp.c
+++ b/fusl/src/string/wcsncasecmp.c
@@ -1,9 +1,11 @@
#include <wchar.h>
#include <wctype.h>
-int wcsncasecmp(const wchar_t *l, const wchar_t *r, size_t n)
-{
- if (!n--) return 0;
- for (; *l && *r && n && (*l == *r || towlower(*l) == towlower(*r)); l++, r++, n--);
- return towlower(*l) - towlower(*r);
+int wcsncasecmp(const wchar_t* l, const wchar_t* r, size_t n) {
+ if (!n--)
+ return 0;
+ for (; *l && *r && n && (*l == *r || towlower(*l) == towlower(*r));
+ l++, r++, n--)
+ ;
+ return towlower(*l) - towlower(*r);
}

Powered by Google App Engine
This is Rietveld 408576698