From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Po Lu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#57969: 29.0.50; `device-class' errors when NAME is nil Date: Wed, 21 Sep 2022 19:54:07 +0800 Message-ID: <87tu51eye8.fsf@yahoo.com> References: <87r105tblc.fsf@gmail.com> Reply-To: Po Lu Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25441"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) Cc: 57969@debbugs.gnu.org To: Visuwesh Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Sep 21 14:24:35 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oaymJ-0006Ue-6G for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 21 Sep 2022 14:24:35 +0200 Original-Received: from localhost ([::1]:56490 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oaymH-00021l-Vt for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 21 Sep 2022 08:24:34 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51102) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oayJi-0002Ap-6T for bug-gnu-emacs@gnu.org; Wed, 21 Sep 2022 07:55:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33682) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oayJh-0002rC-TG for bug-gnu-emacs@gnu.org; Wed, 21 Sep 2022 07:55:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oayJh-00033W-O3 for bug-gnu-emacs@gnu.org; Wed, 21 Sep 2022 07:55:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Po Lu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 21 Sep 2022 11:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57969 X-GNU-PR-Package: emacs Original-Received: via spool by 57969-submit@debbugs.gnu.org id=B57969.166376126611699 (code B ref 57969); Wed, 21 Sep 2022 11:55:01 +0000 Original-Received: (at 57969) by debbugs.gnu.org; 21 Sep 2022 11:54:26 +0000 Original-Received: from localhost ([127.0.0.1]:60993 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oayJ7-00032d-UL for submit@debbugs.gnu.org; Wed, 21 Sep 2022 07:54:26 -0400 Original-Received: from sonic304-21.consmr.mail.ne1.yahoo.com ([66.163.191.147]:33417) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oayJ6-00032P-5N for 57969@debbugs.gnu.org; Wed, 21 Sep 2022 07:54:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1663761257; bh=LS06YR83SDuBfzVVxRgNpV1Qy0D39hApyG88Fjz+woo=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To; b=NM7jK1z2TXDQ22L/tS3ZecAzRWJVgSKMIV49R78Hs0ZWzzoivXPgwZtIEn/H3viPbA1Gr9BRhaDiJuxaFetIJsvOdulIrZxB78CTOGj7cBcybNgLX0RKXpqkOf9UZknehCHrhAytmGN2KKqC1D/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V5Z vE4r83qfy.C8c7Neh4K8MbpkOVbkuYQE9CsXxn_x4lSENQVdgI8epvtjc7RfPDk2AtT8BXz48rZG hmaoMwbNZRK7Yb.rR2yFighvJ8CoaowozyZ6TvSkPspyUS4Qkknkpvzaq_y3L6XWkfxTHSgbMxrV y02Ek6P5eKtmXo3kQb4c5zdadVkVw7WJxG4S3zBZLY.sH3ZU8OzmlZf5D6qf9ko2SrSYIrvjJ6Tw v0lO2zie2MabACEfZ9Lz9RyABpzTjYA6MisxRV9Ay5drMGp9h0Xj0Ov5Bvi5p.p4InRg2e0F3tuc f7PRUyoA_JLy6YN1pi9ZjnYM4IDIOPXVd2tl2UuT8jRNywyNcbZdm_MysYjNYK6xbD7IO2Gneg3p 3bCocHKamz6cQRCM_UgIw6j7jLFCL8_ROIvBe6fT6pIobzERpV4nkCzO2KpDzE3hyeof4mAmt6sY HWeX.yewnsEUAKuQR4tBRJDRUfR2wTFwtmgLRFAcuS X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic304.consmr.mail.ne1.yahoo.com with HTTP; Wed, 21 Sep 2022 11:54:17 +0000 Original-Received: by hermes--production-sg3-6d76f6b48d-sxspw (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 7f0bfe7874d7b01236eaac8faa4dab1e; Wed, 21 Sep 2022 11:54:11 +0000 (UTC) In-Reply-To: <87r105tblc.fsf@gmail.com> (Visuwesh's message of "Wed, 21 Sep 2022 13:15:19 +0530") X-Mailer: WebService/1.1.20663 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:243324 Archived-At: Visuwesh writes: > According to the docstring of `device-class', nil is a valid value for > the NAME argument however it errors out since `x-device-class' uses > `downcase' without checking if NAME is non-nil. Backtrace is below, > > Debugger entered--Lisp error: (wrong-type-argument char-or-string-p nil) > downcase(nil) > (let ((downcased-name (downcase name))) (cond ((string-match-p "XTEST" = name) 'test) ((string=3D "Virtual core pointer" name) 'core-pointer) ((stri= ng=3D "Virtual core keyboard" name) 'core-keyboard) ((string-match-p "erase= r" downcased-name) 'eraser) ((string-match-p " pad" downcased-name) 'pad) (= (or (or (string-match-p "wacom" downcased-name) (string-match-p "pen" downc= ased-name)) (string-match-p "stylus" downcased-name)) 'pen) ((or (string-pr= efix-p "xwayland-touch:" name) (string-match-p "touchscreen" downcased-name= )) 'touchscreen) ((or (string-match-p "trackpoint" downcased-name) (string-= match-p "stick" downcased-name)) 'trackpoint) ((or (string-match-p "mouse" = downcased-name) (string-match-p "optical" downcased-name) (string-match-p "= pointer" downcased-name)) 'mouse) ((string-match-p "cursor" downcased-name)= 'puck) ((or (string-match-p "keyboard" downcased-name) (string=3D name "US= B USB Keykoard")) 'keyboard) ((string-match-p "button" downcased-name) 'pow= er-button) ((string-match-p "touchpad" downcased-name) 'touchpad) ((or (str= ing-match-p "midi" downcased-name) (string-match-p "piano" downcased-name))= 'piano) ((or (string-match-p "wskbd" downcased-name) (and (string-match-p = "/dev" downcased-name) (string-match-p "kbd" downcased-name))) 'keyboard))) > x-device-class(nil) > device-class(# nil) > eval((device-class last-event-frame nil) nil) > elisp--eval-last-sexp(nil) > eval-last-sexp(nil) > eros-eval-last-sexp(nil) > funcall-interactively(eros-eval-last-sexp nil) > call-interactively(eros-eval-last-sexp nil nil) > command-execute(eros-eval-last-sexp) Should be fixed now, thanks.