webdav: fix locking in webdav_ucp::Content::getResourceType()

This commit cherry-picks 49a454225e35699d7351faaba3d296e1858c6107
for serf webdav version.

Change-Id: Ic5aba4fba8f8a2a521224b08865500dd932e85bf
(cherry picked from commit 9da4e46957bd1a69c4339eeb1d107546c400e6e3)
Reviewed-on: https://gerrit.libreoffice.org/10129
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>