summaryrefslogtreecommitdiff
path: root/sal/osl/unx/backtrace.c
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2019-02-05 10:32:03 +0100
committerThorsten Behrens <Thorsten.Behrens@CIB.de>2020-12-14 01:27:36 +0100
commit12f8f2c87ffc8ec6e3e18a6125abe1716733e054 (patch)
treeb0d52665e6fa893612bbdcf172ee31ea7dd9c5c0 /sal/osl/unx/backtrace.c
parent95cbc7e6afe36f01cc4d2a8d7ab54d8facb39208 (diff)
Improve osl_getLocalHostname on Windows
...returning a non-dotted result obtained from gethostname in case trying via osl_createHostAddrByName doesn't work either. The code had been like this ever since its introduction with 74f3ed51f1e3fa7a199210fd6ffc69d78a535c08 "made socket and pipe refcounted, added blocking read write methods, added direct access methods for struct sockaddr", but there appears to be no good reason not to return the non-dotted gethostname value as a fallback (and it may just have been an oversight not to do so; and on e.g. Linux we simply return whatever a successful call to gethostname provides, be it dotted or not, ever since at least ebd00f5c46707e0dfcdd074f581ae86c0576e69b "socket.cxx -> socket.c", too). (Calls to osl_getLocalHostname are few across the code base, so this change in behavior is unlikely to cause any regressions. I came across this wile looking into <https://bugs.documentfoundation.org/show_bug.cgi?id=107461> "Does not support 'file://' scheme with actual hostname", but this change is unrelated to any potential fix for that issue. It just felt right to get this fixed in passing.) Change-Id: I78e59140579b9d37ee435a8f121e58544d2235eb Reviewed-on: https://gerrit.libreoffice.org/67390 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> (cherry picked from commit 3be2a53ee1a34fd4bc96e7817191fc3e0eb3c917) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107495 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'sal/osl/unx/backtrace.c')
0 files changed, 0 insertions, 0 deletions