ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
From: "nagachika (Tomoyuki Chikanaga) via ruby-core" <ruby-core@ml.ruby-lang.org>
To: ruby-core@ml.ruby-lang.org
Cc: "nagachika (Tomoyuki Chikanaga)" <noreply@ruby-lang.org>
Subject: [ruby-core:117387] [Ruby master Bug#20245] Crash when checking symbol encoding
Date: Sun, 31 Mar 2024 10:20:31 +0000 (UTC)	[thread overview]
Message-ID: <redmine.journal-107549.20240331102031.42491@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-20245.20240207163830.42491@ruby-lang.org

Issue #20245 has been updated by nagachika (Tomoyuki Chikanaga).

Backport changed from 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: REQUIRED, 3.3: DONE to 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: DONE, 3.3: DONE

ruby_3_2 27606daf8efeb0ae6d0590a2c9bb1c5aae07f140 merged revision(s) ac0163949a6ee678dfccec9f6e56422b91e5f0a9,01fd262e62076277a41af72ea13f20deb1b462a2.

----------------------------------------
Bug #20245: Crash when checking symbol encoding
https://bugs.ruby-lang.org/issues/20245#change-107549

* Author: peterzhu2118 (Peter Zhu)
* Status: Closed
* Backport: 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: DONE, 3.3: DONE
----------------------------------------
GitHub PR: https://github.com/ruby/ruby/pull/9871

We sometimes pass in a fake string to sym_check_asciionly. This can crash if sym_check_asciionly raises because it creates a CFP with the fake string as the receiver which will crash if GC tries to mark the CFP.

For example, the following script crashes:

```ruby
GC.stress = true
Object.const_defined?("\xC3")
```



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

      parent reply	other threads:[~2024-03-31 10:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-07 16:38 [ruby-core:116622] [Ruby master Bug#20245] Crash when checking symbol encoding peterzhu2118 (Peter Zhu) via ruby-core
2024-03-21  1:29 ` [ruby-core:117275] " naruse (Yui NARUSE) via ruby-core
2024-03-31 10:20 ` nagachika (Tomoyuki Chikanaga) via ruby-core [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.ruby-lang.org/en/community/mailing-lists/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=redmine.journal-107549.20240331102031.42491@ruby-lang.org \
    --to=ruby-core@ruby-lang.org \
    --cc=noreply@ruby-lang.org \
    --cc=ruby-core@ml.ruby-lang.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).