Merge pull request #585 from illwieckz/fixurl

allow to open https:// urls
This commit is contained in:
Timothee "TTimo" Besset 2018-01-27 14:14:56 -06:00 committed by GitHub
commit beaf72c754
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -902,7 +902,8 @@ void MainFrame::process_xlink( Str &FileName, const char *menu_name, const char
if ( !strcmp( (const char*)pNode->name, "item" ) ) { if ( !strcmp( (const char*)pNode->name, "item" ) ) {
// process the URL // process the URL
Str *url; Str *url;
if ( strstr( (char *)xmlGetProp( pNode, (xmlChar *)"url" ), "http://" ) ) { if ( strstr( (char *)xmlGetProp( pNode, (xmlChar *)"url" ), "http://" )
|| strstr( (char *)xmlGetProp( pNode, (xmlChar *)"url" ), "https://" ) ) {
// complete URL // complete URL
url = new Str; url = new Str;
*url = (char *)xmlGetProp( pNode, (xmlChar *)"url" ); *url = (char *)xmlGetProp( pNode, (xmlChar *)"url" );