summaryrefslogtreecommitdiff
path: root/basegfx
diff options
context:
space:
mode:
authorTakeshi Abe <tabe@fixedpoint.jp>2018-03-28 23:50:08 +0900
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-04-06 08:52:14 +0200
commitad8961511ad34e6159db092bde052a4fab4375c7 (patch)
tree2c1fac4ef5405b2850209e3c7928dd76e42306bb /basegfx
parent8091d2142e52447f4d880c979079dd1c2c2e1236 (diff)
osl: Remember the last error before returning osl_Socket_Error
This prevents from e.g. com.sun.star.bridge.UnoUrlResolver's emitting confusing messages, when trying to connect to a port on which no LibreOffice process is listening, like: > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > __main__.NoConnectException: Connector : couldn't connect to socket (Success) ^^^^^^^ After applying this patch: > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > __main__.NoConnectException: Connector : couldn't connect to socket (Connection refused) You can see the above behavior with the following python code: import uno x = uno.getComponentContext() y = x.ServiceManager z = y.createInstanceWithContext("com.sun.star.bridge.UnoUrlResolver", x) url = "uno:socket,host=localhost,port=2002;urp;StarOffice.ComponentContext" a = z.resolve(url) ... provided that no process is waiting on port 2002. Change-Id: Id094cf9271fe77d84f2284d91a0e452448de2bc2 Reviewed-on: https://gerrit.libreoffice.org/52018 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basegfx')
0 files changed, 0 insertions, 0 deletions