Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Treat "\u0000" as "\u0020" for the purposes of message search (message indexing)#10820

Merged
H-Shay merged 27 commits into
matrix-org:developfrom
H-Shay:test_homeserver
Sep 22, 2021
Merged

Treat "\u0000" as "\u0020" for the purposes of message search (message indexing)#10820
H-Shay merged 27 commits into
matrix-org:developfrom
H-Shay:test_homeserver

Conversation

@H-Shay
Copy link
Copy Markdown
Contributor

@H-Shay H-Shay commented Sep 14, 2021

This PR intercepts message bodies with "\u0000" in them and replaces them with "\u0020" before inserting into the search tables in the database, which causes an error in Postgres databases. Fixes #9341.

Pull Request Checklist

  • [ x] Pull request is based on the develop branch
  • [ x] Pull request includes a changelog file. The entry should:
    • Be a short description of your change which makes sense to users. "Fixed a bug that prevented receiving messages from other servers." instead of "Moved X method from EventStore to EventWorkerStore.".
    • Use markdown where necessary, mostly for code blocks.
    • End with either a period (.) or an exclamation mark (!).
    • Start with a capital letter.
  • [ x] Pull request includes a sign off
  • [ x] Code style is correct (run the linters)

Loading
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Internal error when posting an event with \u0000

5 participants