fix semi-deterministic bug with link parser
This commit is contained in:
@@ -170,19 +170,16 @@ parseAnchor:
|
|||||||
|
|
||||||
done:
|
done:
|
||||||
// check host
|
// check host
|
||||||
if (this->hasMatch_)
|
this->hasMatch_ = isValidHostname(host) || isValidIpv4(host)
|
||||||
{
|
|
||||||
this->hasMatch_ = isValidHostname(host) || isValidIpv4(host)
|
|
||||||
#ifdef C_MATCH_IPV6_LINK
|
#ifdef C_MATCH_IPV6_LINK
|
||||||
|
|
||||||
|| (hasHttp && isValidIpv6(host))
|
|| (hasHttp && isValidIpv6(host))
|
||||||
#endif
|
#endif
|
||||||
;
|
;
|
||||||
|
|
||||||
if (this->hasMatch_)
|
if (this->hasMatch_)
|
||||||
{
|
{
|
||||||
this->match_ = unparsedString;
|
this->match_ = unparsedString;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ public:
|
|||||||
QString getCaptured() const;
|
QString getCaptured() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
bool hasMatch_;
|
bool hasMatch_{false};
|
||||||
QString match_;
|
QString match_;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user