fdo#77039: Fill the match string even if the raw string is empty.

And in case of an empty string, call svl::SharedString::getEmptyString()
to get an empty shared string instance.

(cherry picked from commit 50708577850544920c746ebc382d47275452a761)

Conflicts:
	sc/source/core/tool/queryparam.cxx

Change-Id: I0923e59f03468790270de8ef22323c0cedad002f
Reviewed-on: https://gerrit.libreoffice.org/9155
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>