From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 638BE3858D33 for ; Mon, 13 Feb 2023 10:29:59 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 638BE3858D33 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676284198; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=iUFKolhcU8D2JPrdq6bzKFsySaUiX0zYo6P7s4qg+q0=; b=F3fM2zXTqzAYKzeNyThfuGRQClhI2L6umB88f6JjnraNSd/clnoPFeVLGQMgl0sv8RTHVi xrey9hIJsbHNnNS3kdxHkRaRYeZDuEnFSbuLgr2k83wsO4q12poXhmFQxu+tpgOJd5JgIv qZikzq+DTc+NYjFZT7f1fOJ6YogfHzA= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-341-7Ou3uMQGOQOAys_bytBSnQ-1; Mon, 13 Feb 2023 05:29:57 -0500 X-MC-Unique: 7Ou3uMQGOQOAys_bytBSnQ-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 3684B3806706; Mon, 13 Feb 2023 10:29:57 +0000 (UTC) Received: from oldenburg.str.redhat.com (unknown [10.2.16.7]) by smtp.corp.redhat.com (Postfix) with ESMTPS id BACEB492B15; Mon, 13 Feb 2023 10:29:56 +0000 (UTC) From: Florian Weimer To: Nima Hamidi via Libc-help Cc: Nima Hamidi Subject: Re: Using dlmope/dlopem with RTLD_GLOBAL References: <14297fb9-70cb-42b1-a477-6fb68c03ff64@Spark> <052bc685-e6bb-4fbb-a696-f6810bdab1f6@Spark> Date: Mon, 13 Feb 2023 11:29:55 +0100 In-Reply-To: <052bc685-e6bb-4fbb-a696-f6810bdab1f6@Spark> (Nima Hamidi via Libc-help's message of "Mon, 13 Feb 2023 03:23:26 -0600") Message-ID: <87v8k5g8nw.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: * Nima Hamidi via Libc-help: > The error won=E2=80=99t happen if I=C2=A0dlopen=C2=A0with=C2=A0RTLD_LOCAL= =C2=A0in b.cpp rather > than RTLD_GLOBAL. I would appreciate any help on what I=E2=80=99m doing w= rong > here. I think I see what's going on. The add_to_global_resize function does not take into account that the global scope does not exist yet when it is called. Would you please file a bug in Bugzilla? Thanks, Florian