From a0c54ff9a6b92d220a1eb7099dd2ecd2bd92056f Mon Sep 17 00:00:00 2001 From: Markus Mohrhard Date: Tue, 1 Aug 2017 20:39:39 +0200 Subject: updater: extract the build ID generation into own method Change-Id: Ieee90215c155d031da40b2d9d0b50bc41ff2e980 Reviewed-on: https://gerrit.libreoffice.org/40652 Tested-by: Jenkins Reviewed-by: Markus Mohrhard --- desktop/source/app/updater.cxx | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'desktop/source/app/updater.cxx') diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx index 782bfef9079b..24891fa8ae8e 100644 --- a/desktop/source/app/updater.cxx +++ b/desktop/source/app/updater.cxx @@ -668,8 +668,7 @@ void update_checker() } OUString aProductName = utl::ConfigManager::getProductName(); - OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" SAL_CONFIGFILE("version") ":buildid}"); - rtl::Bootstrap::expandMacros(aBuildID); + OUString aBuildID = Updater::getBuildID(); OUString aBuildTarget = "${_OS}_${_ARCH}"; rtl::Bootstrap::expandMacros(aBuildTarget); OUString aChannel = officecfg::Office::Update::Update::UpdateChannel::get(); @@ -813,4 +812,12 @@ void Updater::log(const char* pMessage) aLog.WriteCharPtr(pMessage); } +OUString Updater::getBuildID() +{ + OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" SAL_CONFIGFILE("version") ":buildid}"); + rtl::Bootstrap::expandMacros(aBuildID); + + return aBuildID; +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit