summaryrefslogtreecommitdiff
path: root/i18npool
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-01-28 17:53:30 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-01-28 17:56:18 +0100
commitcead54b6e555fe907348943b4586e956771f6ad0 (patch)
tree509e515c969fa27449fd7f7674c252e742133aae /i18npool
parented874d2eab1a6b1146f411a5a83cc790d3226f10 (diff)
Use vector::data
...in some places where it is obvious that it does not hurt that for an empty vector the obtained pointer is not necessarily a nullptr. Change-Id: Id5d66b1559ca8b8955d379bcdbfae6986ef46a51
Diffstat (limited to 'i18npool')
-rw-r--r--i18npool/source/collator/gencoll_rule.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/i18npool/source/collator/gencoll_rule.cxx b/i18npool/source/collator/gencoll_rule.cxx
index 827f8127c100..8f71b7e14abe 100644
--- a/i18npool/source/collator/gencoll_rule.cxx
+++ b/i18npool/source/collator/gencoll_rule.cxx
@@ -120,10 +120,10 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv)
if (status == U_BUFFER_OVERFLOW_ERROR) {
data.resize(len);
status = U_ZERO_ERROR;
- len = coll->cloneBinary(data.empty() ? 0 : &data[0], len, status);
+ len = coll->cloneBinary(data.data(), len, status);
}
if (U_SUCCESS(status))
- data_write(argv[2], argv[3], data.empty() ? 0 : &data[0], len);
+ data_write(argv[2], argv[3], data.data(), len);
else {
printf("Could not get rule data from collator\n");
}