Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: NullPointerException was raised on some data URLs #1582

Open
wants to merge 1 commit into
base: fix/1538/css-custom-prop
Choose a base branch
from

Conversation

rdeltour
Copy link
Member

A NullPointerException was raised on data URLs ending with a query-like string.
This was caused by a double-bug in Galimatias:

  • removing the query-like string (as we do when registering references) with URL#withQuery(null) resulted in a hierarchical URL despite data URLs being non-hierarchical.
  • such hybrid data URLs caused an NPE to be raised when canonicalized

We now add some check to not remove the query component on non-hierarchical URLs.

Also, OCFContainer#isRemote(URL) now returns false without further checks for data URLs.

Fixes #1536

A NullPointerException was raised on `data` URLs ending with a query-like
string.
This was caused by a double-bug in Galimatias:
- removing the query-like string (as we do when registering references)
  with `URL#withQuery(null)` resulted in a hierarchical URL despite
  `data` URLs being non-hierarchical.
- such hybrid `data` URLs caused an NPE to be raised when canonicalized

We now add some check to not remove the query component on non-hierarchical
URLs.

Also, `OCFContainer#isRemote(URL)` now returns false without further checks
for `data` URLs.

Fixes #1536
@rdeltour rdeltour added the status: ready to merge The pull request is ready to be merged label Dec 23, 2024
@rdeltour rdeltour added this to the Next maintenance release milestone Dec 23, 2024
@rdeltour rdeltour self-assigned this Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: ready to merge The pull request is ready to be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant