]> git.ipfire.org Git - thirdparty/open-vm-tools.git/commitdiff
stringxx: Replace usage of deprecated glibmm function
authorJohn Wolfe <jwolfe@vmware.com>
Thu, 4 Mar 2021 21:48:46 +0000 (13:48 -0800)
committerJohn Wolfe <jwolfe@vmware.com>
Thu, 4 Mar 2021 21:48:46 +0000 (13:48 -0800)
Glibmm::RefPtr::clear() has been deprecated for a while and was removed in
2.51. The reasoning is listed in the 2.44 header:

"/// @deprecated Use reset() instead because this leads to confusion with
clear() methods on the underlying class."

reset() has been available since 2.16, so it is trivial to switch to it.

open-vm-tools/services/plugins/dndcp/stringxx/ubstr_t.hh

index 1558db86513a73717c45e5f90fde65d1a78a7703..df08fb8d6447de40994e441566984f5f206c7c66 100644 (file)
@@ -863,7 +863,7 @@ ubstr_t::GetUTF8Cache()
 inline void
 ubstr_t::InvalidateCache()
 {
-   mUTF8.clear();
+   mUTF8.reset();
 }