Lionel, anyone,

Do you happen to have insight into this, how to trigger the code? (Found in preparation for <https://gerrit.libreoffice.org/#/c/16371/> "Catch inadvertent uses of OUString(sal_Unicode) ctor.")

On 06/19/2015 11:04 AM, Stephan Bergmann wrote:
commit e46e8d19458fd64ff20b1013e5eeabd07e62379c
Author: Stephan Bergmann <[email protected]>
Date:   Fri Jun 19 10:11:31 2015 +0200

     Shall this produce a string representation of a number?

     On the one hand, the code had apparently treated nIdx as a sal_Unicode 
character
     value ever since its inception in e718950884fa2db240822e1711f301b39a70ad3e 
"new
     querydesign."  On the other hand, the preceding BROW_VIS_ROW case does 
produce
     strings "0" and "1".

     Change-Id: Ife6e98ba32146cc469b722fa4f013c12152b5505

diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx 
b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
index 64ecc68..954638d 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
@@ -2245,7 +2245,7 @@ OUString OSelectionBrowseBox::GetCellContents(sal_Int32 
nCellIndex, sal_uInt16 n
              sal_Int32 nIdx = m_pOrderCell->GetSelectEntryPos();
              if (nIdx == LISTBOX_ENTRY_NOTFOUND)
                  nIdx = 0;
-            return OUString(nIdx);
+            return OUString::number(nIdx);
          }
          default:
              return GetCellText(nCellIndex, nColId);

_______________________________________________
LibreOffice mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to