|
|
DescriptionFix Cronet compilation error due to different kCharsetLatin1 definition.
BUG=
Committed: https://crrev.com/e0c0e05376669677e0330a571cfe6650abd28c91
Cr-Commit-Position: refs/heads/master@{#313924}
Patch Set 1 #
Total comments: 5
Patch Set 2 : Added comment. #Messages
Total messages: 11 (2 generated)
mef@chromium.org changed reviewers: + mmenke@chromium.org, xunjieli@chromium.org
PTAL, this fixes Cronet compilation error due to different kCharsetLatin1 definition.
thanks for taking care of the buildbots! https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... File net/base/net_string_util_icu_alternatives_android.cc (right): https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... net/base/net_string_util_icu_alternatives_android.cc:69: const char* const kCharsetLatin1 = "ISO-8859-1"; I think crrev.com/696033002 was trying to change char* to char[]. The latter seems to be the recommended style, so we should probably not change it back to char*. How about change the declaration in net_string_util.h to char[] and the definition in net/base/net_string_util_icu.cc to char[] as well?
https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... File net/base/net_string_util_icu_alternatives_android.cc (right): https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... net/base/net_string_util_icu_alternatives_android.cc:69: const char* const kCharsetLatin1 = "ISO-8859-1"; On 2015/01/28 15:54:57, xunjieli wrote: > I think crrev.com/696033002 was trying to change char* to char[]. The latter > seems to be the recommended style, so we should probably not change it back to > char*. How about change the declaration in net_string_util.h to char[] and the > definition in net/base/net_string_util_icu.cc to char[] as well? Unfortunately changing net_string_util_icu to const char kCharsetLatin1[] = base::kCodepageLatin1; gets an error ../../net/base/net_string_util_icu.cc:14:12: error: array initializer must be an initializer list or string literal as base::kCodepageLatin1 is also const char [].
lgtm https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... File net/base/net_string_util_icu_alternatives_android.cc (right): https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... net/base/net_string_util_icu_alternatives_android.cc:69: const char* const kCharsetLatin1 = "ISO-8859-1"; On 2015/01/28 19:06:59, mef wrote: > On 2015/01/28 15:54:57, xunjieli wrote: > > I think crrev.com/696033002 was trying to change char* to char[]. The latter > > seems to be the recommended style, so we should probably not change it back to > > char*. How about change the declaration in net_string_util.h to char[] and the > > definition in net/base/net_string_util_icu.cc to char[] as well? > > Unfortunately changing net_string_util_icu to > > const char kCharsetLatin1[] = base::kCodepageLatin1; > > gets an error > > ../../net/base/net_string_util_icu.cc:14:12: error: array initializer must be an > initializer list or string literal > > as base::kCodepageLatin1 is also const char []. > > Ahh, i see. Maybe add a comment here so it won't get changed to char[] in future cleanup?
LGTM, with the comment added. https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... File net/base/net_string_util_icu_alternatives_android.cc (right): https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... net/base/net_string_util_icu_alternatives_android.cc:69: const char* const kCharsetLatin1 = "ISO-8859-1"; On 2015/01/28 19:15:22, xunjieli wrote: > On 2015/01/28 19:06:59, mef wrote: > > On 2015/01/28 15:54:57, xunjieli wrote: > > > I think crrev.com/696033002 was trying to change char* to char[]. The > latter > > > seems to be the recommended style, so we should probably not change it back > to > > > char*. How about change the declaration in net_string_util.h to char[] and > the > > > definition in net/base/net_string_util_icu.cc to char[] as well? > > > > Unfortunately changing net_string_util_icu to > > > > const char kCharsetLatin1[] = base::kCodepageLatin1; > > > > gets an error > > > > ../../net/base/net_string_util_icu.cc:14:12: error: array initializer must be > an > > initializer list or string literal > > > > as base::kCodepageLatin1 is also const char []. > > > > > > Ahh, i see. Maybe add a comment here so it won't get changed to char[] in future > cleanup? SGTM
Thanks! https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... File net/base/net_string_util_icu_alternatives_android.cc (right): https://codereview.chromium.org/880003002/diff/1/net/base/net_string_util_icu... net/base/net_string_util_icu_alternatives_android.cc:69: const char* const kCharsetLatin1 = "ISO-8859-1"; On 2015/01/30 15:28:23, mmenke wrote: > On 2015/01/28 19:15:22, xunjieli wrote: > > On 2015/01/28 19:06:59, mef wrote: > > > On 2015/01/28 15:54:57, xunjieli wrote: > > > > I think crrev.com/696033002 was trying to change char* to char[]. The > > latter > > > > seems to be the recommended style, so we should probably not change it > back > > to > > > > char*. How about change the declaration in net_string_util.h to char[] and > > the > > > > definition in net/base/net_string_util_icu.cc to char[] as well? > > > > > > Unfortunately changing net_string_util_icu to > > > > > > const char kCharsetLatin1[] = base::kCodepageLatin1; > > > > > > gets an error > > > > > > ../../net/base/net_string_util_icu.cc:14:12: error: array initializer must > be > > an > > > initializer list or string literal > > > > > > as base::kCodepageLatin1 is also const char []. > > > > > > > > > > Ahh, i see. Maybe add a comment here so it won't get changed to char[] in > future > > cleanup? > > SGTM Done.
The CQ bit was checked by mef@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/880003002/20001
Message was sent while issue was closed.
Committed patchset #2 (id:20001)
Message was sent while issue was closed.
Patchset 2 (id:??) landed as https://crrev.com/e0c0e05376669677e0330a571cfe6650abd28c91 Cr-Commit-Position: refs/heads/master@{#313924} |