From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS4713 221.184.0.0/13 X-Spam-Status: No, score=-3.5 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.0 Received: from neon.ruby-lang.org (neon.ruby-lang.org [221.186.184.75]) by dcvr.yhbt.net (Postfix) with ESMTP id A2B421F42D for ; Fri, 1 Jun 2018 22:23:40 +0000 (UTC) Received: from neon.ruby-lang.org (localhost [IPv6:::1]) by neon.ruby-lang.org (Postfix) with ESMTP id A3E34120AB8; Sat, 2 Jun 2018 07:23:37 +0900 (JST) Received: from o1678916x28.outbound-mail.sendgrid.net (o1678916x28.outbound-mail.sendgrid.net [167.89.16.28]) by neon.ruby-lang.org (Postfix) with ESMTPS id 71D22120AB7 for ; Sat, 2 Jun 2018 07:23:35 +0900 (JST) Received: by filter0092p3mdw1.sendgrid.net with SMTP id filter0092p3mdw1-14011-5B11C763-1D 2018-06-01 22:23:31.725508198 +0000 UTC Received: from herokuapp.com (ec2-54-197-95-79.compute-1.amazonaws.com [54.197.95.79]) by ismtpd0043p1mdw1.sendgrid.net (SG) with ESMTP id 7I2QJ0FVQK2FhwaeTKbRQg for ; Fri, 01 Jun 2018 22:23:31.622 +0000 (UTC) Date: Fri, 01 Jun 2018 22:23:32 +0000 (UTC) From: merch-redmine@jeremyevans.net To: ruby-core@ruby-lang.org Message-ID: References: Mime-Version: 1.0 X-Redmine-MailingListIntegration-Message-Ids: 62710 X-Redmine-Project: ruby-trunk X-Redmine-Issue-Id: 14807 X-Redmine-Issue-Author: jeremyevans0 X-Redmine-Issue-Assignee: normalperson X-Redmine-Sender: jeremyevans0 X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-SG-EID: ync6xU2WACa70kv/Ymy4QrNMhiuLXJG8OTL2vJD1yS7DRg17bWawyd5arLSfSJEkGjOKsuT44225au qdhZTL3azDLGGVwwm+T9dtY54Xjkooyd6wd3tcK7K3XZUDjoBp74FJ0i1Mflz0772XkCEf05c+8HI6 CsRWIOTOHnNdKAL+99SEhbFjDFOWW7eUAmhR6TGJxfI2fSC2KMXaEaNXMw== X-ML-Name: ruby-core X-Mail-Count: 87347 Subject: [ruby-core:87347] [Ruby trunk Bug#14807] 2.6.0-preview2 segfaults on OpenBSD due to missing pthread_condattr_init call X-BeenThere: ruby-core@ruby-lang.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Ruby developers List-Id: Ruby developers List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ruby-core-bounces@ruby-lang.org Sender: "ruby-core" Issue #14807 has been updated by jeremyevans0 (Jeremy Evans). normalperson (Eric Wong) wrote: > Btw, is PTHREAD_COND_INITIALIZER supported on OpenBSD? It's defined but I don't think it would be usable: ~~~ /usr/include/pthread.h:#define PTHREAD_COND_INITIALIZER NULL ~~~ ---------------------------------------- Bug #14807: 2.6.0-preview2 segfaults on OpenBSD due to missing pthread_condattr_init call https://bugs.ruby-lang.org/issues/14807#change-72336 * Author: jeremyevans0 (Jeremy Evans) * Status: Open * Priority: Normal * Assignee: normalperson (Eric Wong) * Target version: * ruby -v: ruby 2.6.0dev (2018-06-01 trunk 63545) [x86_64-openbsd] * Backport: 2.3: DONTNEED, 2.4: DONTNEED, 2.5: DONTNEED ---------------------------------------- r63238 refactored thread_pthread.c, and where there was previously a pthread_condattr_init call to initialize the pthread_condattr_t value, it removed the call and passed the pthread_condattr_t* directly to pthread_condattr_setclock without initializing the value by calling pthread_condattr_init first. On some operating systems that works, but it's not required to work, and it segfaults on OpenBSD because the pthread_condattr_t is not initialized. The attached patch should fix the problem. ---Files-------------------------------- 0001-Initialize-condattr_monotonic-via-pthread_condattr_i.patch (1.08 KB) -- https://bugs.ruby-lang.org/