Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


Hello,

Quite recently, an interesting bt has been published by "bfoman" about this
bug (see https://bugs.freedesktop.org/attachment.cgi?id=62055) , here are
the top lines :
sal3!rtl_uString_newFromAscii+0x15
wininetbe1_uno!rtl::OUString::createFromAscii+0x40
wininetbe1_uno!WinInetBackend::WinInetBackend+0x1a0

Searching about "createFromAscii" in "wininetbackend" files, I found them in
"wininetbackend.cxx"
The only lines containing "createFromAscii" are :
  157             rtl::OUString aProxyList       =
rtl::OUString::createFromAscii( lpi->lpszProxy );
  158             rtl::OUString aProxyBypassList =
rtl::OUString::createFromAscii( lpi->lpszProxyBypass );

Then I wonder what was "lpi" type and just read some lines above :
126             LPINTERNET_PROXY_INFO lpi = NULL;

Then searching about LPINTERNET_PROXY_INFO gave this url :
http://msdn.microsoft.com/en-us/library/windows/desktop/aa385148%28v=vs.85%29.aspx
"
typedef struct {
  DWORD   dwAccessType;
  LPCTSTR lpszProxy;
  LPCTSTR lpszProxyBypass;
} INTERNET_PROXY_INFO, * LPINTERNET_PROXY_INFO;
"
So kept on with attributes "lpszProxy" and "lpszProxyBypass" and its type
LPCTSTR, it gave this link :
http://msdn.microsoft.com/en-us/library/aa383751%28v=vs.85%29.aspx
"
This type is declared in WinNT.h as follows:

#ifdef UNICODE
 typedef LPCWSTR LPCTSTR; 
#else
 typedef LPCSTR LPCTSTR;
#endif
"

On the same page, we can read :
for LPCSTR :
"
A pointer to a constant null-terminated string of 8-bit Windows (ANSI)
characters. For more information, see Character Sets Used By Fonts.

This type is declared in WinNT.h as follows:

typedef __nullterminated CONST CHAR *LPCSTR;
"

and for LPCWSTR :
"
A pointer to a constant null-terminated string of 16-bit Unicode characters.
For more information, see Character Sets Used By Fonts.

This type is declared in WinNT.h as follows:

typedef CONST WCHAR *LPCWSTR;
"

Then going back to createFromAscii to see if it could match with all this :
sal/inc/rtl/ustring.hxx    :     static OUString createFromAscii( const
sal_Char * value ) SAL_THROW(())
+
sal/inc/sal/types.h      :     typedef char  sal_Char;

Now I wonder if it's ok to use createFromAscii to manage the attributes 
"lpszProxy" and "lpszProxyBypass" ? (no ironical question here, just a
beginner question only :-))

Julien.


--
View this message in context: 
http://nabble.documentfoundation.org/About-fdo-47044-crashed-when-accessing-Proxy-etc-tp3986891.html
Sent from the Dev mailing list archive at Nabble.com.

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.