From unknown Sun Aug 10 16:49:22 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#44349 <44349@debbugs.gnu.org> To: bug#44349 <44349@debbugs.gnu.org> Subject: Status: 28.0.50; Assertion failure on macOS when resizing frame Reply-To: bug#44349 <44349@debbugs.gnu.org> Date: Sun, 10 Aug 2025 23:49:22 +0000 retitle 44349 28.0.50; Assertion failure on macOS when resizing frame reassign 44349 emacs submitter 44349 Philipp severity 44349 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 11:52:05 2020 Received: (at submit) by debbugs.gnu.org; 31 Oct 2020 15:52:05 +0000 Received: from localhost ([127.0.0.1]:34331 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtAi-0000jm-1P for submit@debbugs.gnu.org; Sat, 31 Oct 2020 11:52:05 -0400 Received: from lists.gnu.org ([209.51.188.17]:45260) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtAS-0000j7-7V for submit@debbugs.gnu.org; Sat, 31 Oct 2020 11:52:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42688) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kYtAR-0006N4-Te for bug-gnu-emacs@gnu.org; Sat, 31 Oct 2020 11:51:47 -0400 Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]:55978) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kYtAP-0002CM-GX for bug-gnu-emacs@gnu.org; Sat, 31 Oct 2020 11:51:47 -0400 Received: by mail-wm1-x32a.google.com with SMTP id c9so3899804wml.5 for ; Sat, 31 Oct 2020 08:51:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version; bh=rQ/eVMk3zPPLAF9uXYtE6li9i99UM5HkrOvzjRYrKLk=; b=Tu8I1E3xrXZnuLw1qixSL+/oRRczOK/Mm3TYh42agbSfv6S7NP2fdqwd8mZc+5mXQC AlPTSqkC2m2oYRhmB+2LwfyfCqElo8vxcJVMZYYcU+7q0buZcQKOsWSRr45oq6OKDLKz eHSowQenlLJGbbSNxdorfeahNn4c2JHk+WMd9oHOJ/aXVHEhQ3lLK4Awjh5c+E1iY5nA VV/k53ptN1oTyPOuQsu329rBJR66VjkrX4oFZdoXE0cNLwlovoTyS6cutxbY0wTTZQa/ GaHNdxTlet+5r5EFapEyP5e7XuFelEmrRIFjZPy97sguSU0PTU7va95LngTogiO/I7hf +T2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=rQ/eVMk3zPPLAF9uXYtE6li9i99UM5HkrOvzjRYrKLk=; b=GGPQ5/71HATSqwE8dB6x0fj3H06NfR7KbClBFrJZeG0nMHKewi+ZWuKXkD4pWI9UZr ETi2BZVg2omSRkYkvlgL58bogrqtJNtzLHqnkK3j4ucgto030WyyjXpBc1HvhVkfRY8b 7AevpwQHRx1ubb57Xa+QbqAGFq1hdtsCFEkZUPpavegGtsHwRyLkJ6kBfEkplHXDp2fP 5K0ies8xVDBrVLUFRZC2IqtVp1LxWoq09QpSZnDMoWqFP7QHw9edFScOX8HkQ6HTjUqO dAvj2sreFOtxXDFHGslQZ3qlG6x5xDQLhgRd/O0uG+K+v1XcrZoHs8dimtpAak1BEacQ fHJw== X-Gm-Message-State: AOAM531Q/Mm0FEfizbSEW/7qOFzmTQarqDOnHX6O6fV9jm0q2gd3p2MD LprxkG5WB5zPLDWj9smPMd5lf9wi/bg= X-Google-Smtp-Source: ABdhPJy2y/Yt5XWVU5Ax7Yh8si5MwtgblbfTRTQdgV1s/UqCrqo6uIhmS/Xl3l5Y7sUqkI8A92qeVw== X-Received: by 2002:a1c:9cd8:: with SMTP id f207mr8457707wme.76.1604159503210; Sat, 31 Oct 2020 08:51:43 -0700 (PDT) Received: from p ([46.128.199.221]) by smtp.gmail.com with ESMTPSA id b2sm4891856wmd.40.2020.10.31.08.51.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 31 Oct 2020 08:51:42 -0700 (PDT) From: Philipp To: bug-gnu-emacs@gnu.org Subject: 28.0.50; Assertion failure on macOS when resizing frame Date: Sat, 31 Oct 2020 16:51:41 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2a00:1450:4864:20::32a; envelope-from=p.stephani2@gmail.com; helo=mail-wm1-x32a.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 2.3 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: 1. Compile Emacs with assertions enabled on macOS. 2. Start it in graphical mode. 3. Try to resize the frame by dragging the lower-right corner. This will trigger an assertion failure doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) Fatal error 6: Aborted Abort trap: 6 Content analysis details: (2.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.2 FREEMAIL_ENVFROM_END_DIGIT Envelope-from freemail username ends in digit (p.stephani2[at]gmail.com) 0.0 T_SPF_TEMPERROR SPF: test of record failed (temperror) 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (p.stephani2[at]gmail.com) 2.0 SPOOFED_FREEMAIL No description available. X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.1 (--) 1. Compile Emacs with assertions enabled on macOS. 2. Start it in graphical mode. 3. Try to resize the frame by dragging the lower-right corner. This will trigger an assertion failure doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) Fatal error 6: Aborted Abort trap: 6 LLDB backtrace: doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) Process 21775 stopped * thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT frame #0: 0x00007fff71cda33a libsystem_kernel.dylib`__pthread_kill + 10 libsystem_kernel.dylib`__pthread_kill: -> 0x7fff71cda33a <+10>: jae 0x7fff71cda344 ; <+20> 0x7fff71cda33c <+12>: movq %rax, %rdi 0x7fff71cda33f <+15>: jmp 0x7fff71cd4629 ; cerror_nocancel 0x7fff71cda344 <+20>: retq Target 0: (emacs) stopped. (lldb) bt * thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT * frame #0: 0x00007fff71cda33a libsystem_kernel.dylib`__pthread_kill + 10 frame #1: 0x00007fff71d96e60 libsystem_pthread.dylib`pthread_kill + 430 frame #2: 0x00007fff71bf193e libsystem_c.dylib`raise + 26 frame #3: 0x0000000100bcae19 emacs`terminate_due_to_signal(sig=, backtrace_limit=) at emacs.c:408:3 [opt] frame #4: 0x0000000100bcb42d emacs`emacs_abort at sysdep.c:2280:3 [opt] frame #5: 0x0000000100aaab36 emacs`ns_term_shutdown(sig=6) at nsterm.m:5729:7 [opt] frame #6: 0x00000001005c7634 emacs`shut_down_emacs(sig=, stuff=) at emacs.c:2472:3 [opt] frame #7: 0x0000000100bcad30 emacs`terminate_due_to_signal(sig=6, backtrace_limit=) at emacs.c:391:11 [opt] frame #8: 0x0000000100bcb9d9 emacs`die(msg=, file=, line=) at alloc.c:7341:3 [opt] frame #9: 0x00000001009acf6f emacs`doprnt(buffer=, bufsize=9223372036854775797, format=, format_end=, ap=) at doprnt.c:493:4 [opt] frame #10: 0x00000001009adcfc emacs`esprintf(buf="*scratch* ??????????????????????????????????????", format=) at doprnt.c:535:12 [opt] frame #11: 0x0000000100abc0d5 emacs`-[EmacsView windowWillResize:toSize:](self=, _cmd=, sender=, frameSize=) at nsterm.m:7286:2 [opt] frame #12: 0x00007fff34ed2737 AppKit`-[NSWindow _confirmSize:force:] + 323 frame #13: 0x00007fff3581d006 AppKit`-[NSWindow(NSWindowResizing) _validFrameForFrame:resizedFromEdge:] + 94 frame #14: 0x00007fff35176b8d AppKit`-[NSTitledFrame _validFrameForResizeFrame:fromResizeEdge:] + 425 frame #15: 0x00007fff3581cf68 AppKit`-[NSWindow(NSWindowResizing) _commonValidFrameForResizeFrame:fromResizeEdge:] + 157 frame #16: 0x00007fff35819cd5 AppKit`-[NSWindow(NSWindowResizing) _frame:resizedFromEdge:withDelta:withEvent:withState:] + 3531 frame #17: 0x00007fff35176065 AppKit`-[NSWindow(NSWindowResizing) _resizeWithEvent:] + 2486 frame #18: 0x00007fff3504bfe6 AppKit`-[NSTitledFrame attemptResizeWithEvent:] + 177 frame #19: 0x00007fff3504bcc7 AppKit`-[NSThemeFrame handleMouseDown:] + 294 frame #20: 0x00007fff350e9248 AppKit`-[NSThemeFrame mouseDown:] + 30 frame #21: 0x00007fff34fce5f0 AppKit`-[NSWindow(NSEventRouting) _handleMouseDownEvent:isDelayedEvent:] + 4914 frame #22: 0x00007fff34f38e21 AppKit`-[NSWindow(NSEventRouting) _reallySendEvent:isDelayedEvent:] + 2612 frame #23: 0x00007fff34f381c9 AppKit`-[NSWindow(NSEventRouting) sendEvent:] + 349 frame #24: 0x00007fff34f36554 AppKit`-[NSApplication(NSEvent) sendEvent:] + 352 frame #25: 0x0000000100aab8e5 emacs`-[EmacsApp sendEvent:](self=, _cmd=, theEvent=) at nsterm.m:5902:3 [opt] frame #26: 0x00007fff34d835bf AppKit`-[NSApplication run] + 707 frame #27: 0x0000000100aab09a emacs`-[EmacsApp run](self=, _cmd=) at nsterm.m:5771:9 [opt] frame #28: 0x0000000100aa67ee emacs`ns_select(nfds=, readfds=, writefds=, exceptfds=, timeout=, sigmask=) at nsterm.m:4861:3 [opt] frame #29: 0x000000010095e00d emacs`wait_reading_process_output(time_limit=, nsecs=, read_kbd=, do_display=, wait_for_cell=, wait_proc=0x0000000000000000, just_wait_proc=) at process.c:5609:18 [opt] frame #30: 0x0000000100612281 emacs`kbd_buffer_get_event(kbp=, used_mouse_menu=, end_time=) at keyboard.c:3874:4 [opt] frame #31: 0x00000001006110b7 emacs`read_event_from_main_queue(end_time=, local_getcjmp=, used_mouse_menu=) at keyboard.c:2160:7 [opt] frame #32: 0x00000001005ea5e3 emacs`read_decoded_event_from_main_queue(end_time=, local_getcjmp=, prev_event=, used_mouse_menu=) at keyboard.c:2224:11 [opt] frame #33: 0x00000001005e5b49 emacs`read_char(commandflag=1, map=(i = 0x0000629000019573), prev_event=(i = 0x0000000000000000), used_mouse_menu=, end_time=0x0000000000000000) at keyboard.c:2834:11 [opt] frame #34: 0x00000001005d8647 emacs`read_key_sequence(keybuf=, prompt=, dont_downcase_last=, can_return_switch_frame=, fix_current_buffer=, prevent_redisplay=) at keyboard.c:9552:12 [opt] frame #35: 0x00000001005d3fd1 emacs`command_loop_1 at keyboard.c:1354:15 [opt] frame #36: 0x0000000100863be5 emacs`internal_condition_case(bfun=(emacs`command_loop_1 at keyboard.c:1240), handlers=, hfun=(emacs`cmd_error at keyboard.c:923)) at eval.c:1359:25 [opt] frame #37: 0x000000010060fd68 emacs`command_loop_2(ignore=(i = 0x0000000000000000)) at keyboard.c:1095:11 [opt] frame #38: 0x00000001008629b6 emacs`internal_catch(tag=(i = 0x000000000000c990), func=(emacs`command_loop_2 at keyboard.c:1091), arg=(i = 0x0000000000000000)) at eval.c:1120:25 [opt] frame #39: 0x00000001005d14d0 emacs`command_loop at keyboard.c:1074:2 [opt] frame #40: 0x00000001005d11c9 emacs`recursive_edit_1 at keyboard.c:718:9 [opt] frame #41: 0x00000001005d189f emacs`Frecursive_edit at keyboard.c:790:3 [opt] frame #42: 0x00000001005ca4a6 emacs`main(argc=0, argv=) at emacs.c:2047:3 [opt] frame #43: 0x00007fff71b92cc9 libdyld.dylib`start + 1 In GNU Emacs 28.0.50 (build 89, x86_64-apple-darwin19.6.0, NS appkit-1894.60 Version 10.15.7 (Build 19H2)) of 2020-10-31 Repository revision: 283b8d274bd54192b3876ce8bf2930a096391839 Repository branch: master Windowing system distributor 'Apple', version 10.3.1894 System Description: Mac OS X 10.15.7 Configured using: 'configure --with-modules --without-xml2 --without-pop --with-mailutils --enable-gcc-warnings=warn-only --enable-checking=all --enable-check-lisp-object-type 'CFLAGS=-g3 -O1 -fsanitize=address -fsanitize=undefined -fno-omit-frame-pointer'' Configured features: JPEG TIFF GIF PNG NOTIFY KQUEUE ACL GNUTLS ZLIB TOOLKIT_SCROLL_BARS NS MODULES THREADS JSON PDUMPER LCMS2 Important settings: value of $LANG: de_DE.UTF-8 locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: tooltip-mode: t global-eldoc-mode: t eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message rmc dired dired-loaddefs rfc822 mml easymenu mml-sec epa epg epg-config gnus-util rmail rmail-loaddefs time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils phst skeleton derived edmacro kmacro pcase ffap thingatpt url url-proxy url-privacy url-expand url-methods url-history url-cookie url-domsuf url-util url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs password-cache json map url-vars mailcap rx gnutls puny dbus xml subr-x seq byte-opt gv bytecomp byte-compile cconv compile text-property-search comint ansi-color ring cl-loaddefs cl-lib tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/ns-win ns-win ucs-normalize mule-util term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote threads kqueue cocoa ns lcms2 multi-tty make-network-process emacs) Memory information: ((conses 16 70870 3425) (symbols 48 8580 1) (strings 32 23868 1428) (string-bytes 1 780264) (vectors 16 14940) (vector-slots 8 197741 15083) (floats 8 26 26) (intervals 56 212 0) (buffers 992 10)) From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 11:58:12 2020 Received: (at 44349) by debbugs.gnu.org; 31 Oct 2020 15:58:12 +0000 Received: from localhost ([127.0.0.1]:34341 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtGe-0000u7-0a for submit@debbugs.gnu.org; Sat, 31 Oct 2020 11:58:12 -0400 Received: from mail-ot1-f51.google.com ([209.85.210.51]:43946) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtGc-0000tu-QK for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 11:58:11 -0400 Received: by mail-ot1-f51.google.com with SMTP id a6so8462990otp.10 for <44349@debbugs.gnu.org>; Sat, 31 Oct 2020 08:58:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :content-transfer-encoding; bh=RCaJI04MS6rVlxhc1lN1HOZiCYgBJU2NNhHpZHc001c=; b=N0IERWTh5ceclu43xHNKiF6cYrUB2S2f83Kg4r1lIzMW3MV3UUiOhouifq+ai/DHTQ rhLBlPQv+TqVTBQRbOLOvB11WoCceSejr7hOnOyIbtgfLUJmDSwuX4ZIf6Mk4sXhJQZ4 iu3CXAImt18acMxzPdYrF4jPRctcx44IUPVdJTiHWGrAK0m0MG9HoXV1aOdaUl1ZhxgZ 92P3EwtLWiC0CuST46aDpyK9ZhklCvPmuZSpE28w6XpY3e6oLSe4vkMhRStFwVDT6i0r EYzajx85osAWbMColdRyafopSot+UoZl/FHH/vbHz10sv4MJrehOVZE/6iXQbA2grROu vDhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:content-transfer-encoding; bh=RCaJI04MS6rVlxhc1lN1HOZiCYgBJU2NNhHpZHc001c=; b=UhEDOCh7aowYlkPHvzJ/jY7fat1SjkWZmHiYR5RqTplr3oQkrIPv1ghbu6S40NjnUe 9N2YeVBl4kTixEJtkNVPWmj6j33FfBmKVJHDTLkXlPMl+6b1QBsoRC2SB83yVDAUgFD0 FfMJheBOFv0g6g6A7qKR2yNPH8Y5f9TkdvnPJB5WqOeNOIeP7cj+UKxc2viKAwKOBPmL Ed4n0E4uG+w7frlLKl4Kmb0mlAFCoAI8hVeCHa1wex+hEyAy9Bt21/kUPyLyUlrYR150 lH3OsWGJPZrvT5Rp0xely7T5SpGoghSc2A9tqrmmNd4PiOyJSrLApb3OGKKRhP7uBEGr GLSQ== X-Gm-Message-State: AOAM531/8mK/nGvgU+i9dyGTxHQKbu7fJBg2KtIsNz/rzMZH+9b+F1SW HEYLKGfwM/NSYE5EjMLwBkjxxw+djKlZr0NtXa2h207bkNg= X-Google-Smtp-Source: ABdhPJwsrWGecRGXx3cnu+4pN+V6JNata0tQx+dZgCZJm7bUsyirXd8Z8dhlEy4QbqI4lv9MLc7yxThe+vQ0FPL61tw= X-Received: by 2002:a9d:4504:: with SMTP id w4mr5747027ote.36.1604159884908; Sat, 31 Oct 2020 08:58:04 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Philipp Stephani Date: Sat, 31 Oct 2020 16:57:54 +0100 Message-ID: Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame To: 44349@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 44349 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) Am Sa., 31. Okt. 2020 um 16:53 Uhr schrieb Philipp : > > > 1. Compile Emacs with assertions enabled on macOS. > 2. Start it in graphical mode. > 3. Try to resize the frame by dragging the lower-right corner. > > This will trigger an assertion failure > > doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) > Fatal error 6: Aborted > Abort trap: 6 > Here's a better backtrace with fewer arguments optimized out: * thread #1, queue =3D 'com.apple.main-thread', stop reason =3D signal SIGA= BRT * frame #0: 0x00007fff71cda33a libsystem_kernel.dylib`__pthread_kill + 10 frame #1: 0x00007fff71d96e60 libsystem_pthread.dylib`pthread_kill + 430 frame #2: 0x00007fff71bf193e libsystem_c.dylib`raise + 26 frame #3: 0x00000001004a8332 emacs`terminate_due_to_signal(sig=3D6, backtrace_limit=3D40) at emacs.c:408:3 frame #4: 0x00000001004a8743 emacs`emacs_abort at sysdep.c:2280:3 frame #5: 0x000000010043b8d8 emacs`ns_term_shutdown(sig=3D6) at nsterm.m:5729:7 frame #6: 0x00000001001b3b89 emacs`shut_down_emacs(sig=3D6, stuff=3D(i =3D 0x0000000000000000)) at emacs.c:2472:3 frame #7: 0x00000001004a82ca emacs`terminate_due_to_signal(sig=3D6, backtrace_limit=3D2147483647) at emacs.c:391:11 frame #8: 0x00000001004a8bec emacs`die(msg=3D"ASCII_CHAR_P (fmtchar)", file=3D"doprnt.c", line=3D493) at alloc.c:7341:3 frame #9: 0x00000001003c9a9e emacs`doprnt(buffer=3D"*scratch* ", bufsize=3D9223372036854775797, format=3D"%s =E2=80=94 (%d x %d)", format_end=3D0x0000000000000000, ap=3D0x00007ffeefbfb750) at doprnt.c:493:4 frame #10: 0x00000001003ca54d emacs`esprintf(buf=3D"*scratch* ", format=3D"%s =E2=80=94 (%d x %d)") at doprnt.c:535:12 frame #11: 0x000000010044364f emacs`-[EmacsView windowWillResize:toSize:](self=3D0x0000000101463a70, _cmd=3D"windowWillResize:toSize:", sender=3D0x0000000101464810, frameSize=3D(width =3D 598, height =3D 570)) at nsterm.m:7286:2 frame #12: 0x00007fff34ed2737 AppKit`-[NSWindow _confirmSize:force:] + = 323 frame #13: 0x00007fff3581d006 AppKit`-[NSWindow(NSWindowResizing) _validFrameForFrame:resizedFromEdge:] + 94 frame #14: 0x00007fff35176b8d AppKit`-[NSTitledFrame _validFrameForResizeFrame:fromResizeEdge:] + 425 frame #15: 0x00007fff3581cf68 AppKit`-[NSWindow(NSWindowResizing) _commonValidFrameForResizeFrame:fromResizeEdge:] + 157 frame #16: 0x00007fff35819cd5 AppKit`-[NSWindow(NSWindowResizing) _frame:resizedFromEdge:withDelta:withEvent:withState:] + 3531 frame #17: 0x00007fff35176065 AppKit`-[NSWindow(NSWindowResizing) _resizeWithEvent:] + 2486 frame #18: 0x00007fff3504bfe6 AppKit`-[NSTitledFrame attemptResizeWithEvent:] + 177 frame #19: 0x00007fff3504bcc7 AppKit`-[NSThemeFrame handleMouseDown:] += 294 frame #20: 0x00007fff350e9248 AppKit`-[NSThemeFrame mouseDown:] + 30 frame #21: 0x00007fff34fce5f0 AppKit`-[NSWindow(NSEventRouting) _handleMouseDownEvent:isDelayedEvent:] + 4914 frame #22: 0x00007fff34f38e21 AppKit`-[NSWindow(NSEventRouting) _reallySendEvent:isDelayedEvent:] + 2612 frame #23: 0x00007fff34f381c9 AppKit`-[NSWindow(NSEventRouting) sendEvent:] + 349 frame #24: 0x00007fff34f36554 AppKit`-[NSApplication(NSEvent) sendEvent:] + 352 frame #25: 0x000000010043be14 emacs`-[EmacsApp sendEvent:](self=3D0x0000000101348bb0, _cmd=3D"sendEvent:", theEvent=3D0x0000000109a5b440) at nsterm.m:5902:3 frame #26: 0x00007fff34d835bf AppKit`-[NSApplication run] + 707 frame #27: 0x000000010043b98a emacs`-[EmacsApp run](self=3D0x0000000101348bb0, _cmd=3D"run") at nsterm.m:5771:9 frame #28: 0x00000001004399ab emacs`ns_select(nfds=3D0, readfds=3D0x00007ffeefbfd2c0, writefds=3D0x00007ffeefbfd240, exceptfds=3D0x0000000000000000, timeout=3D0x00007ffeefbfd218, sigmask=3D0x0000000000000000) at nsterm.m:4861:3 frame #29: 0x000000010039c79b emacs`wait_reading_process_output(time_limit=3D0, nsecs=3D0, read_kbd=3D-1, do_display=3Dtrue, wait_for_cell=3D(i =3D 0x0000000000000000), wait_proc=3D0x0000000000000000, just_wait_proc=3D0) at process.c:5609:18 frame #30: 0x00000001001de3a5 emacs`kbd_buffer_get_event(kbp=3D0x00007ffeefbfd640, used_mouse_menu=3D0x00007ffeefbfea0f, end_time=3D0x0000000000000000) at keyboard.c:3874:4 frame #31: 0x00000001001dd624 emacs`read_event_from_main_queue(end_time=3D0x0000000000000000, local_getcjmp=3D0x00007ffeefbfe3a0, used_mouse_menu=3D0x00007ffeefbfea0f) at keyboard.c:2160:7 frame #32: 0x00000001001c75a9 emacs`read_decoded_event_from_main_queue(end_time=3D0x0000000000000000, local_getcjmp=3D0x00007ffeefbfe3a0, prev_event=3D(i =3D 0x0000000000000000)= , used_mouse_menu=3D0x00007ffeefbfea0f) at keyboard.c:2224:11 frame #33: 0x00000001001c33d0 emacs`read_char(commandflag=3D1, map=3D(i =3D 0x0000000101863da3), prev_event=3D(i =3D 0x0000000000000000), used_mouse_menu=3D0x00007ffeefbfea0f, end_time=3D0x0000000000000000) at keyboard.c:2834:11 frame #34: 0x00000001001bba4f emacs`read_key_sequence(keybuf=3D0x00007ffeefbff030, prompt=3D(i =3D 0x0000000000000000), dont_downcase_last=3Dfalse, can_return_switch_frame=3Dtrue, fix_current_buffer=3Dtrue, prevent_redisplay=3Dfalse) at keyboard.c:9552:12 frame #35: 0x00000001001b9e52 emacs`command_loop_1 at keyboard.c:1354:1= 5 frame #36: 0x00000001002f38ef emacs`internal_condition_case(bfun=3D(emacs`command_loop_1 at keyboard.c:1240), handlers=3D(i =3D 0x0000000000000090), hfun=3D(emacs`cmd_error at keyboard.c:923)) at eval.c:1359:25 frame #37: 0x00000001001dc631 emacs`command_loop_2(ignore=3D(i =3D 0x0000000000000000)) at keyboard.c:1095:11 frame #38: 0x00000001002f2cda emacs`internal_catch(tag=3D(i =3D 0x000000000000c990), func=3D(emacs`command_loop_2 at keyboard.c:1091), arg=3D(i =3D 0x0000000000000000)) at eval.c:1120:25 frame #39: 0x00000001001b8906 emacs`command_loop at keyboard.c:1074:2 frame #40: 0x00000001001b8744 emacs`recursive_edit_1 at keyboard.c:718:= 9 frame #41: 0x00000001001b8b76 emacs`Frecursive_edit at keyboard.c:790:3 frame #42: 0x00000001001b57cf emacs`main(argc=3D2, argv=3D0x00007ffeefbff6e0) at emacs.c:2047:3 frame #43: 0x00007fff71b92cc9 libdyld.dylib`start + 1 From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 12:04:06 2020 Received: (at 44349) by debbugs.gnu.org; 31 Oct 2020 16:04:06 +0000 Received: from localhost ([127.0.0.1]:34345 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtML-00039z-Q1 for submit@debbugs.gnu.org; Sat, 31 Oct 2020 12:04:06 -0400 Received: from mail-ot1-f52.google.com ([209.85.210.52]:45032) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtMJ-00039S-J3 for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 12:04:04 -0400 Received: by mail-ot1-f52.google.com with SMTP id m26so8455637otk.11 for <44349@debbugs.gnu.org>; Sat, 31 Oct 2020 09:04:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :content-transfer-encoding; bh=1xdQSUNlfALfahb+DEDOI9cyrWfdkY8u8RyxASLxfTI=; b=Q6TCHcqpsJmSmpK2zABJNEC/KIMUy7dWXlc14smudx6/AHzSSZ288Qid9PWlKgtNJi IYdRiwDofp2EFltjO5q8ULmzwu8EH0yQNp71BQGsRdMiAu7dcfRJEN9jAiLy6Dwvhyoi bc90Nvkfgd2lf2Oy1oK/7ZwjPSLVncI8SLx/LajPFdCBVdEqQ1Fozm5Zjjyrjud5ivq9 x9cn96pSosLnf3eB0uCO0BHPcD+YsKJmjKXcaNnJ7Q5qMKeIouH/ujiFcSESOnPzWDKj E6CHtQC75DtFMxZi8sPly6OxL6sm/USm/+uBRI251SAzYFmZh1n9mOROUjHt2RStltpB bd4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:content-transfer-encoding; bh=1xdQSUNlfALfahb+DEDOI9cyrWfdkY8u8RyxASLxfTI=; b=TP2a8Mh40Y/IKsFLykzeg/nhawYhs8HpQG1eZBHxJnuojBMhAx4Sh3LMCaM+BHNlxQ U1+lztWePO/gt+RVqfaJKKl4Al8ioQAjhlRO7nHFLFVO9RMZJx2mJDMrwq8E5Lri0h0S ZWJ5TdQ6QD4GoNFk+NdVrogHBfvZGQ3U3WNGvwnkIvb+769aWduWdNiAviJWARBPX8Ll 7q2BE/PcclxVqfMuWWh51ZBmbj17jvyo17mGllFWblzfcossyG22wPwSLp2LHbBD3W8R Wlgp77SW3LRe/cPI+xongFm+6Moc62gZKIcqHLk95sQ0Y0ju6RjGXJjHH9UrvS6ippbA uq8g== X-Gm-Message-State: AOAM531pfPVGXAbQsnOnDPByUeS+odrbUYXzn67wpTgKv5+EyUQqQweq bqRwAohqSwSWZ2PDETJC0TYBngWgoJiSSyWxYcCtEWgu X-Google-Smtp-Source: ABdhPJz8MvApyFEqa5gyPX7nY5g1j7VSm8ReC9hOSct9Ij0xJJXS6PyGh1TMOmD65nOgjULA6jHnAcy9E/ExOh80tHQ= X-Received: by 2002:a9d:12f3:: with SMTP id g106mr5582737otg.149.1604160237687; Sat, 31 Oct 2020 09:03:57 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Philipp Stephani Date: Sat, 31 Oct 2020 17:03:46 +0100 Message-ID: Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame To: 44349@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 44349 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) Am Sa., 31. Okt. 2020 um 16:57 Uhr schrieb Philipp Stephani : > frame #10: 0x00000001003ca54d emacs`esprintf(buf=3D"*scratch* ", > format=3D"%s =E2=80=94 (%d x %d)") at doprnt.c:535:12 > frame #11: 0x000000010044364f emacs`-[EmacsView > windowWillResize:toSize:](self=3D0x0000000101463a70, > _cmd=3D"windowWillResize:toSize:", sender=3D0x0000000101464810, > frameSize=3D(width =3D 598, height =3D 570)) at nsterm.m:7286:2 The issue here is the non-ASCII format string. No idea whether that's supposed to be supported or not. From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 12:35:37 2020 Received: (at 44349) by debbugs.gnu.org; 31 Oct 2020 16:35:37 +0000 Received: from localhost ([127.0.0.1]:34406 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtqr-00068a-Ck for submit@debbugs.gnu.org; Sat, 31 Oct 2020 12:35:37 -0400 Received: from eggs.gnu.org ([209.51.188.92]:49236) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtqp-00068N-47 for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 12:35:36 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:40678) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kYtqj-00078U-Qz; Sat, 31 Oct 2020 12:35:29 -0400 Received: from [176.228.60.248] (port=2439 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kYtqj-0004Qy-2j; Sat, 31 Oct 2020 12:35:29 -0400 Date: Sat, 31 Oct 2020 18:35:13 +0200 Message-Id: <83eelegxq6.fsf@gnu.org> From: Eli Zaretskii To: Philipp Stephani In-Reply-To: (message from Philipp Stephani on Sat, 31 Oct 2020 16:57:54 +0100) Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philipp Stephani > Date: Sat, 31 Oct 2020 16:57:54 +0100 > > > doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) > > Fatal error 6: Aborted > > Abort trap: 6 I cannot say I understand why that assertion is there. From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 12:44:18 2020 Received: (at 44349) by debbugs.gnu.org; 31 Oct 2020 16:44:18 +0000 Received: from localhost ([127.0.0.1]:34411 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtzG-0006Ld-9r for submit@debbugs.gnu.org; Sat, 31 Oct 2020 12:44:18 -0400 Received: from mail-oo1-f51.google.com ([209.85.161.51]:39643) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYtzC-0006LQ-T6 for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 12:44:17 -0400 Received: by mail-oo1-f51.google.com with SMTP id j12so2340059oou.6 for <44349@debbugs.gnu.org>; Sat, 31 Oct 2020 09:44:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=aLhp2AYWsraTTPSX4wZaxztX+QDU1X9c2r2Qd7+eoTE=; b=VVSQP8NWSiOPT/UiivRjo1Gu7VR/73xUjEIUL4lDXnfV047S/mgOtoJDVMYLa7aW7n WsT+45lpGBnI/FGl/F+WMaPVuSVBsKSYxxnJRmJx8r6FUQYSarwYyab1sa+CqdJHHSTX AZ495QgjPGeoUaaAhBZGHR7prZtPzaOJ/O2cqjqcTlhFutRPHJPRFRrUOd4ILh5QlyHz LSjLNR1YnUWBRquEhvBycyEI/R73lB3TOBki+J2PhjM7S/oKvBqQhDR8FOCACnRV7g0D hxqp0ZkZyKJQhYMcedaCYPj0YNun7Tif65lPB7kp3LZb/lOJPsnDwqwZLmUSD3q9JNiS o87Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=aLhp2AYWsraTTPSX4wZaxztX+QDU1X9c2r2Qd7+eoTE=; b=SlUSOjwDuMPP4ohP/wFroOcVpGTv2EZNm5WrbdcDa95KfKpiHokden5U6I9asbdfrA cGX8DqkRLSGXSQVMdjT/GoseiCffDqLtf++Q93OAPxNH072Cfc+VqkT9BLpxVtrOQpuv LgBziISXFBt28RLio1mMkzJxT8lChI9EI0LnkGZQ3QuBH0YzQBd70J6l4zXrUx0UdcFm 6VAUfpltbyHZSrZ5SGW/jyFqMgIEpORHCc0ptC+6Q4d4LP1XGg/IBK5Y2Mn+3AkaLS44 937i/GAVjuH5okl2oKNOinJ4AKCnCBGe9jAUEhhpyPRQ/bfDFMWJlc+WyltSNO36ax6K o/uA== X-Gm-Message-State: AOAM533VKK+PBFqtCF5F7Uc5kFkTP1r3Xv7griD62o7sHytxIYb7tHKs 6Kq+oteJHusDjMAZvwIjZpd6kU6ybRfy4QuePE0= X-Google-Smtp-Source: ABdhPJxNCoS9NCknhXvxibqrLeSa+9i3RJWK6BVkwAXLUXah64p2HS8Fi3Zq7VttPCxBzeqMuw0NL2mV4wPV9TFTFtw= X-Received: by 2002:a4a:dcc8:: with SMTP id h8mr6060384oou.81.1604162648945; Sat, 31 Oct 2020 09:44:08 -0700 (PDT) MIME-Version: 1.0 References: <83eelegxq6.fsf@gnu.org> In-Reply-To: <83eelegxq6.fsf@gnu.org> From: Philipp Stephani Date: Sat, 31 Oct 2020 17:43:57 +0100 Message-ID: Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame To: Eli Zaretskii Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) Am Sa., 31. Okt. 2020 um 17:35 Uhr schrieb Eli Zaretskii : > > > From: Philipp Stephani > > Date: Sat, 31 Oct 2020 16:57:54 +0100 > > > > > doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) > > > Fatal error 6: Aborted > > > Abort trap: 6 > > I cannot say I understand why that assertion is there. Line 81 of doprnt.c states that non-ASCII characters aren't supported. That would mean that nsterm.m can't use (only) esprintf to generate the size hint when resizing. From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 12:52:30 2020 Received: (at 44349) by debbugs.gnu.org; 31 Oct 2020 16:52:30 +0000 Received: from localhost ([127.0.0.1]:34432 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYu7B-0006Zn-TZ for submit@debbugs.gnu.org; Sat, 31 Oct 2020 12:52:30 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51992) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYu7A-0006Za-DR for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 12:52:28 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:40855) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kYu75-0000ea-3Y; Sat, 31 Oct 2020 12:52:23 -0400 Received: from [176.228.60.248] (port=3472 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kYu74-0006Ye-EO; Sat, 31 Oct 2020 12:52:22 -0400 Date: Sat, 31 Oct 2020 18:52:08 +0200 Message-Id: <83a6w2gwxz.fsf@gnu.org> From: Eli Zaretskii To: Philipp Stephani In-Reply-To: (message from Philipp Stephani on Sat, 31 Oct 2020 17:43:57 +0100) Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: <83eelegxq6.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philipp Stephani > Date: Sat, 31 Oct 2020 17:43:57 +0100 > Cc: 44349@debbugs.gnu.org > > Am Sa., 31. Okt. 2020 um 17:35 Uhr schrieb Eli Zaretskii : > > > > > From: Philipp Stephani > > > Date: Sat, 31 Oct 2020 16:57:54 +0100 > > > > > > > doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) > > > > Fatal error 6: Aborted > > > > Abort trap: 6 > > > > I cannot say I understand why that assertion is there. > > Line 81 of doprnt.c states that non-ASCII characters aren't supported. I don't see why we would want to enforce that, it sounds like a grave limitation. Maybe I'm missing some background here. The version we have on emacs-27 does support non-ASCII characters in the format. From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 20:55:40 2020 Received: (at 44349) by debbugs.gnu.org; 1 Nov 2020 00:55:40 +0000 Received: from localhost ([127.0.0.1]:34971 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZ1el-0006CO-RC for submit@debbugs.gnu.org; Sat, 31 Oct 2020 20:55:40 -0400 Received: from wilbur.contactoffice.com ([212.3.242.68]:54300) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZ1ej-0006C8-Iv for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 20:55:38 -0400 Received: from smtpauth2.co-bxl (smtpauth2.co-bxl [10.2.0.24]) by wilbur.contactoffice.com (Postfix) with ESMTP id DCFA9B5E; Sun, 1 Nov 2020 01:55:30 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1604192130; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To; l=1350; bh=gzfP3uyeCZbLRNwwdxcO63AISwOdZhclOCjaRvtjIOY=; b=erMs3XIiX8UJ5jJhf8uiWPHJ8VlwhEu8mQWoSvgmzYuDhkLkD6WiaBgEDWWsZOGs 838ExV52ChRnyDXAOAX3N9JpI5iqEWWNgUTbFGwlmJUTE8Q2PPw9Fr3xGuXxC6PIQM/ xeKEkdQbp1Lw+wF8n0tndJXK16URJIuDN7l8UBlluvCr/+3Kt1nHbj37kYnA2fdhCxs o0D6PD1cKsac5RiE8s++lTZkygnQaAEVZTKAiEW/0x9KOeyHHuZIPxttNjQN6zPjFzP dh8joPrus1tApvni8qYSfZHBv9YBuQLIcJhJdgMVQoP1iEckxybuoXpHMZ2WncoV2/G CnXtBjqqCg== Received: by smtp.mailfence.com with ESMTPA ; Sun, 1 Nov 2020 01:55:29 +0100 (CET) Received: by breton.holly.idiocy.org (Postfix, from userid 501) id 56EEC20264C1D0; Sun, 1 Nov 2020 00:55:29 +0000 (GMT) Date: Sun, 1 Nov 2020 00:55:29 +0000 From: Alan Third To: Philipp Stephani Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame Message-ID: <20201101005529.GO59267@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Philipp Stephani , 44349@debbugs.gnu.org References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Flag: NO X-Spam-Status: No, hits=-1.0 required=4.7 symbols=ALL_TRUSTED device=10.2.0.21 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sat, Oct 31, 2020 at 04:57:54PM +0100, Philipp Stephani wrote: > Am Sa., 31. Okt. 2020 um 16:53 Uhr schrieb Philipp : > > > > > > 1. Compile Emacs with assertions enabled on macOS. > > 2. Start it in graphical mode. > > 3. Try to resize the frame by dragging the lower-right corner. > > > > This will trigger an assertion failure > > > > doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) > > Fatal error 6: Aborted > > Abort trap: 6 > > > frame #8: 0x00000001004a8bec emacs`die(msg="ASCII_CHAR_P > (fmtchar)", file="doprnt.c", line=493) at alloc.c:7341:3 > frame #9: 0x00000001003c9a9e emacs`doprnt(buffer="*scratch* ", > bufsize=9223372036854775797, format="%s — (%d x %d)", > format_end=0x0000000000000000, ap=0x00007ffeefbfb750) at > doprnt.c:493:4 > frame #10: 0x00000001003ca54d emacs`esprintf(buf="*scratch* ", > format="%s — (%d x %d)") at doprnt.c:535:12 > frame #11: 0x000000010044364f emacs`-[EmacsView > windowWillResize:toSize:](self=0x0000000101463a70, > _cmd="windowWillResize:toSize:", sender=0x0000000101464810, > frameSize=(width = 598, height = 570)) at nsterm.m:7286:2 Hmm, it's this line: esprintf (size_title, "%s — (%d x %d)", old_title, cols, rows); where old_title is UTF8. What is the right thing to do here? -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 20:59:07 2020 Received: (at 44349) by debbugs.gnu.org; 1 Nov 2020 00:59:07 +0000 Received: from localhost ([127.0.0.1]:34975 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZ1i7-0006HZ-AN for submit@debbugs.gnu.org; Sat, 31 Oct 2020 20:59:07 -0400 Received: from wilbur.contactoffice.com ([212.3.242.68]:54436) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZ1i5-0006H5-6G for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 20:59:05 -0400 Received: from smtpauth2.co-bxl (smtpauth2.co-bxl [10.2.0.24]) by wilbur.contactoffice.com (Postfix) with ESMTP id B2CEA133F; Sun, 1 Nov 2020 01:58:59 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1604192339; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Subject:Message-ID:References:MIME-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To; l=320; bh=MERhnjfxcmf/VY8bbccovtpO+gQruesoznP7z7nMQQ4=; b=Fwts6mQ0hYkjGjCvdP8udW8l0Pum3wFp+5icT8fP60u5AYgi62y1hF2519akMQ6j dHP34Rnrw/PRi0T2XnOM439hF+Y2gR/4AiFLtopi6ynW+fGPzw1nG2dp3yya/G72Lsu L5SUWAnx7nPkimD9z8Yq9zLETLpoqHpmZ6ZZ9vaq9B9tz6qEU29FOl/O4eufiOLxj1w 4Wts/uMzyCYWSFHkAWfWuGbIy4B+/KGOqVsrnebsi0hKZGo6rNv7+e/jlf2cn97GCZk j338iFSqZfNOa5wiKqZ0UHFw/NjbXRuyiJwsjlr2/qKqIMFleq4JwUN+VjYaUZPSMRQ Z/C8dlRW3w== Received: by smtp.mailfence.com with ESMTPA ; Sun, 1 Nov 2020 01:58:55 +0100 (CET) Received: by breton.holly.idiocy.org (Postfix, from userid 501) id A625620264C2CE; Sun, 1 Nov 2020 00:58:55 +0000 (GMT) Date: Sun, 1 Nov 2020 00:58:55 +0000 From: Alan Third To: Philipp Stephani , 44349@debbugs.gnu.org Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame Message-ID: <20201101005855.GP59267@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Philipp Stephani , 44349@debbugs.gnu.org References: <20201101005529.GO59267@breton.holly.idiocy.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20201101005529.GO59267@breton.holly.idiocy.org> X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.20 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44349 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sun, Nov 01, 2020 at 12:55:29AM +0000, Alan Third wrote: > > Hmm, it's this line: > > esprintf (size_title, "%s — (%d x %d)", old_title, cols, rows); > > where old_title is UTF8. What is the right thing to do here? ignore me, I'm away on the wrong track and you're way ahead of me anyway. -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 31 21:00:53 2020 Received: (at 44349) by debbugs.gnu.org; 1 Nov 2020 01:00:53 +0000 Received: from localhost ([127.0.0.1]:34982 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZ1jo-0006Lz-TU for submit@debbugs.gnu.org; Sat, 31 Oct 2020 21:00:53 -0400 Received: from quimby.gnus.org ([95.216.78.240]:55670) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZ1jm-0006Li-0O for 44349@debbugs.gnu.org; Sat, 31 Oct 2020 21:00:51 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID :In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=BcUc51/LWeWOmBYf0RWjZuebkZyH6egJw9Jcb5V4gkI=; b=pC4Wu8cQ/R7a/PyJGOqsJmQyaN E6pJuhPaBhaaHyfdJgINUBvTK8TDXj2AXWLCZIZA6/tTFeYMVwSbR5CdGSc/4aeDW8e0l8wxg9Hbz zrpNwEl4DYZTIsD/B9fYWn4QuFYuXKPaLnCjMGy2vrT/BEho/PTyxLCNFYo/42qwPPNE=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kZ1jX-0008Ue-KC; Sun, 01 Nov 2020 02:00:42 +0100 From: Lars Ingebrigtsen To: Alan Third Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: <20201101005529.GO59267@breton.holly.idiocy.org> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAG1BMVEVHJR9AKixHJBtm gJus3PWsrq2/YCvjn2L///8rhcJvAAAAAWJLR0QIht6VegAAAAd0SU1FB+QLAQEAAmGhrlsAAAGX SURBVDjLdZRdbsMgDIBptAs0ygEI1d63LNrzopjxOk3QHmCFXCBprj+DIdA/S+0Dn2x/GAhjD2O3 Z+JhcPYEIBHtR4p9Xmc7JnrY4o1XrKo4q3ybFsDEgJGWKFoYXYweOlqLGTKBcwBYimgPCfzBUGyl auAzERjKfTRwdG5aQneZzN8Z4wf4ds5Is7lpbczYErDKZ+HP2aM5zc4NCLyWNUZarWCFWSkltfnF Hl5r1lJqrWfQYH21uYvAmJM5LiiwGLssk5yZB6glc+8QQxj7AdRmBGRbswimFePip1Wn/SFArZXi ck5jDEBoORFwFr4K4LVihgVsyzeAWrHWCiMvSr1moGVRCqelNgB1kZG11jlreWt/uiS2wE8B6HQD CVoZNFAjudHyE3jxxz5FUPYIpzvdaHnQepB8u6JUuI3Tja8IWjKuo2/SIgBph0vU2tHDaeB0N0Yh nkzrHnQZPBwj3W4tc/ehAFda0VckrbgTl7QIHEDmJ4pvfAPlox64yBn4GUgZeD95Aa6/IyVgVfjH N16JJxm0/g/Ah/XmIQnAfgAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMC0xMS0wMVQwMTowMDowMisw MDowMFp4hNEAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjAtMTEtMDFUMDE6MDA6MDIrMDA6MDArJTxt AAAAAElFTkSuQmCC X-Now-Playing: Instant Life's _I turned my best friends into slaves_: "Catholic Confession" Date: Sun, 01 Nov 2020 02:00:34 +0100 In-Reply-To: <20201101005529.GO59267@breton.holly.idiocy.org> (Alan Third's message of "Sun, 1 Nov 2020 00:55:29 +0000") Message-ID: <87zh41howd.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Alan Third writes: > Hmm, it's this line: > > esprintf (size_title, "%s — (%d x %d)", old_title, cols, rows); > > where old_title is UTF8. What is the right thing to do here? Isn't the problem the EM DASH (—) in the format string itself? Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, Philipp Stephani X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Alan Third writes: > Hmm, it's this line: > > esprintf (size_title, "%s =E2=80=94 (%d x %d)", old_title, cols, ro= ws); > > where old_title is UTF8. What is the right thing to do here? Isn't the problem the EM DASH (=E2=80=94) in the format string itself? --=20 (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 27 05:02:06 2020 Received: (at control) by debbugs.gnu.org; 27 Nov 2020 10:02:06 +0000 Received: from localhost ([127.0.0.1]:44035 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kiaZp-0006dp-Ty for submit@debbugs.gnu.org; Fri, 27 Nov 2020 05:02:06 -0500 Received: from quimby.gnus.org ([95.216.78.240]:59644) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kiaZo-0006dK-1e for control@debbugs.gnu.org; Fri, 27 Nov 2020 05:02:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=rJq6SH50zC9kErK+2+IrnNXSpe8OOD/xcVmPnzArwUA=; b=JivSzHmQ1qOCN/aWIkNnYXgd0G syIqXas0RBXVm/lL4UhRJ1/p654NhJYIl7SasatzQWgcXxJRu5ygvE2IHPpsjf01JSKeJS/dTXzJz u+HP2syzJ2HziikZMCIcAxufIFhxGF/Kb1Bqd2jsOTaUk+Sk2+O7WgA7q8kB9SADvVuo=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kiaZf-0005nz-Dj for control@debbugs.gnu.org; Fri, 27 Nov 2020 11:01:57 +0100 Date: Fri, 27 Nov 2020 11:01:54 +0100 Message-Id: <87eekfjey5.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #44850 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: forcemerge 44850 44349 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) forcemerge 44850 44349 quit From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 27 17:24:43 2020 Received: (at 44349) by debbugs.gnu.org; 27 Nov 2020 22:24:43 +0000 Received: from localhost ([127.0.0.1]:46494 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kimAV-000213-8j for submit@debbugs.gnu.org; Fri, 27 Nov 2020 17:24:43 -0500 Received: from wilbur.contactoffice.com ([212.3.242.68]:40426) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kimAS-00020p-56 for 44349@debbugs.gnu.org; Fri, 27 Nov 2020 17:24:42 -0500 Received: from smtpauth1.co-bxl (smtpauth1.co-bxl [10.2.0.15]) by wilbur.contactoffice.com (Postfix) with ESMTP id 8DC14D72; Fri, 27 Nov 2020 23:24:34 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1606515874; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:In-Reply-To; l=3321; bh=QrT+TVdBJH5HuHhl+1mqiZJ/5+xx/W8BKKeHYt7+enY=; b=O2oIf8PUQxzAD+OupcbAtGJky8jZ9dw4WBNbSDWzmXE2e0UKAcs4SldbncJb6iso 6YcwWi1WGPsgdWzUZTL4EpPLuVrhqn3H1hsvWK0orHmqbKMYoXwp5ybBEbNhNWXHfGv ArurFzIc9MZ/GI5YVoaHxIAg3DHTEYU1nXPwKCUetmj5hAV/zd8Fjdafl45rHPUS+Av uC3k2MjsubWRKtmarVVVzlzAFL2w4R9X8S02M75SeqEi1nuu0f5WEEa7sTKDJcOgEgd NSRHETKDc+N4XadC0O/z2C/e5yJWuBtuZUxZvmxYAQS/Puq9UHnaOSS8n/stA7r07Vd xW7q6++BlQ== Received: by smtp.mailfence.com with ESMTPA ; Fri, 27 Nov 2020 23:24:31 +0100 (CET) Received: by breton.holly.idiocy.org (Postfix, from userid 501) id 496FD202698775; Fri, 27 Nov 2020 22:24:30 +0000 (GMT) Date: Fri, 27 Nov 2020 22:24:29 +0000 From: Alan Third To: Eli Zaretskii Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame Message-ID: <20201127222429.GD26836@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Eli Zaretskii , Philipp Stephani , 44349@debbugs.gnu.org References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="ikeVEW9yuYc//A+q" Content-Disposition: inline In-Reply-To: <83a6w2gwxz.fsf@gnu.org> X-Spam-Flag: NO X-Spam-Status: No, hits=-1.0 required=4.7 symbols=ALL_TRUSTED device=10.2.0.21 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, Philipp Stephani X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --ikeVEW9yuYc//A+q Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sat, Oct 31, 2020 at 06:52:08PM +0200, Eli Zaretskii wrote: > > From: Philipp Stephani > > Date: Sat, 31 Oct 2020 17:43:57 +0100 > > Cc: 44349@debbugs.gnu.org > > > > Am Sa., 31. Okt. 2020 um 17:35 Uhr schrieb Eli Zaretskii : > > > > > > > From: Philipp Stephani > > > > Date: Sat, 31 Oct 2020 16:57:54 +0100 > > > > > > > > > doprnt.c:493: Emacs fatal error: assertion failed: ASCII_CHAR_P (fmtchar) > > > > > Fatal error 6: Aborted > > > > > Abort trap: 6 > > > > > > I cannot say I understand why that assertion is there. > > > > Line 81 of doprnt.c states that non-ASCII characters aren't supported. > > I don't see why we would want to enforce that, it sounds like a grave > limitation. Maybe I'm missing some background here. The version we > have on emacs-27 does support non-ASCII characters in the format. Patch attached. I can't see any other special cases that need to be handled and all my tests worked, so I think this is all that's needed. -- Alan Third --ikeVEW9yuYc//A+q Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0001-Allow-doprint-to-handle-multibyte-chars-in-format-bu.patch" >From 7bf4318f34c77e90c76944ee28693a895baf1807 Mon Sep 17 00:00:00 2001 From: Alan Third Date: Fri, 27 Nov 2020 22:11:47 +0000 Subject: [PATCH] Allow doprint to handle multibyte chars in format (bug#44349) * src/doprnt.c (doprnt): Handle the case where fmtchar is the start of a multibyte character. --- src/doprnt.c | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/src/doprnt.c b/src/doprnt.c index 9316497720..841b8249c7 100644 --- a/src/doprnt.c +++ b/src/doprnt.c @@ -77,8 +77,7 @@ where flags is [+ -0], width is [0-9]+, precision is .[0-9]+, and length is empty or l or the value of the pD or pI or PRIdMAX (sans "d") macros. A % that does not introduce a valid %-sequence causes undefined behavior. - ASCII bytes in FORMAT other than % are copied through as-is; - non-ASCII bytes should not appear in FORMAT. + Bytes in FORMAT other than % are copied through as-is. The + flag character inserts a + before any positive number, while a space inserts a space before any positive number; these flags only affect %d, %o, @@ -486,14 +485,30 @@ doprnt (char *buffer, ptrdiff_t bufsize, const char *format, src = uLSQM, srclen = sizeof uLSQM - 1; else if (EQ (quoting_style, Qcurve) && fmtchar == '\'') src = uRSQM, srclen = sizeof uRSQM - 1; - else + else if (! LEADING_CODE_P (fmtchar)) { if (EQ (quoting_style, Qstraight) && fmtchar == '`') fmtchar = '\''; - eassert (ASCII_CHAR_P (fmtchar)); + *bufptr++ = fmtchar; continue; } + else + { + src = fmt0; + srclen = BYTES_BY_CHAR_HEAD (fmtchar); + + /* doprnt_non_null_end doesn't know about multibyte + characters so can truncate format in the middle of one. + If that happens just ignore that character. */ + for ( ; *fmt != 0 && fmt < src + srclen ; fmt++); + + if (fmt < src + srclen) + { + *bufptr++ = '\0'; + break; + } + } if (bufsize < srclen) { -- 2.26.1 --ikeVEW9yuYc//A+q-- From debbugs-submit-bounces@debbugs.gnu.org Sat Nov 28 02:52:19 2020 Received: (at 44349) by debbugs.gnu.org; 28 Nov 2020 07:52:19 +0000 Received: from localhost ([127.0.0.1]:46888 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kiv1n-00010k-2b for submit@debbugs.gnu.org; Sat, 28 Nov 2020 02:52:19 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50842) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kiv1l-00010Z-Nu for 44349@debbugs.gnu.org; Sat, 28 Nov 2020 02:52:18 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:41522) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kiv1f-0003re-RH; Sat, 28 Nov 2020 02:52:11 -0500 Received: from [176.228.60.248] (port=1881 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kiv1f-0000Vh-6Z; Sat, 28 Nov 2020 02:52:11 -0500 Date: Sat, 28 Nov 2020 09:51:57 +0200 Message-Id: <835z5por4y.fsf@gnu.org> From: Eli Zaretskii To: Alan Third In-Reply-To: <20201127222429.GD26836@breton.holly.idiocy.org> (message from Alan Third on Fri, 27 Nov 2020 22:24:29 +0000) Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Fri, 27 Nov 2020 22:24:29 +0000 > From: Alan Third > Cc: Philipp Stephani , 44349@debbugs.gnu.org > > > I don't see why we would want to enforce that, it sounds like a grave > > limitation. Maybe I'm missing some background here. The version we > > have on emacs-27 does support non-ASCII characters in the format. > > Patch attached. > > I can't see any other special cases that need to be handled and all my > tests worked, so I think this is all that's needed. Thanks! Can we add tests for this? > + /* doprnt_non_null_end doesn't know about multibyte > + characters so can truncate format in the middle of one. > + If that happens just ignore that character. */ Is this because the buffer size is measured in characters, not bytes? Or are there other situations where this could happen? Can you give an example? Silently ignoring parts of input sounds ... unusual, so I wonder what would it take to avoid that. How did the old code avoid this problem? From debbugs-submit-bounces@debbugs.gnu.org Sat Nov 28 17:07:04 2020 Received: (at 44349) by debbugs.gnu.org; 28 Nov 2020 22:07:04 +0000 Received: from localhost ([127.0.0.1]:49279 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kj8My-0005N9-Gi for submit@debbugs.gnu.org; Sat, 28 Nov 2020 17:07:04 -0500 Received: from wilbur.contactoffice.com ([212.3.242.68]:52754) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kj8Mv-0005Mf-5c for 44349@debbugs.gnu.org; Sat, 28 Nov 2020 17:07:02 -0500 Received: from smtpauth2.co-bxl (smtpauth2.co-bxl [10.2.0.24]) by wilbur.contactoffice.com (Postfix) with ESMTP id 2F78F98A; Sat, 28 Nov 2020 23:06:50 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1606601210; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:In-Reply-To; l=2254; bh=bPwuGAeFsmQmfNsf0rHmFj/OD2O81h58XapSR2uNFXw=; b=Hf2PaO06ezFOox5iel7WRf/L/QnP3KFxtJsBO5fJKKZEGkZ8i6dL9bH89YRjM1jH WrrHYRlIfDTW3YfL8xbzdBDU9J8l4tbTP3+o3jixCbOH0xRlhoYvr5DKIWIbQxEtaQY 6M//xO/hNBU/YEJd9zbxFg7q8XM5XKJHwUIyuK7rJvZD0xjJhyLoT9HRKMyYqjtf1/X mATHQ03tKTtvwPWA9yZput5ahkhnyMaKu29RUaOsf2uKBY1eneoimYZX4+fkF3x1Xzp YX0zBBp2mou5qtxuZY6CYEvbk2DUeWQwtW8ttcdNKN0dgmBS7UXMvBKQV17CiErxiqF VcVW7VJ7zw== Received: by smtp.mailfence.com with ESMTPA ; Sat, 28 Nov 2020 23:06:47 +0100 (CET) Received: by breton.holly.idiocy.org (Postfix, from userid 501) id ACE3E20269A8BD; Sat, 28 Nov 2020 22:06:45 +0000 (GMT) Date: Sat, 28 Nov 2020 22:06:45 +0000 From: Alan Third To: Eli Zaretskii Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame Message-ID: <20201128220645.GF26836@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Eli Zaretskii , p.stephani2@gmail.com, 44349@debbugs.gnu.org References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> <835z5por4y.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <835z5por4y.fsf@gnu.org> X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.1 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sat, Nov 28, 2020 at 09:51:57AM +0200, Eli Zaretskii wrote: > > Date: Fri, 27 Nov 2020 22:24:29 +0000 > > From: Alan Third > > Cc: Philipp Stephani , 44349@debbugs.gnu.org > > > > Patch attached. > > > > I can't see any other special cases that need to be handled and all my > > tests worked, so I think this is all that's needed. > > Thanks! Can we add tests for this? I was wondering that. How do we add tests for internal C functions? > > + /* doprnt_non_null_end doesn't know about multibyte > > + characters so can truncate format in the middle of one. > > + If that happens just ignore that character. */ > > Is this because the buffer size is measured in characters, not bytes? > Or are there other situations where this could happen? Can you give > an example? > > Silently ignoring parts of input sounds ... unusual, so I wonder what > would it take to avoid that. How did the old code avoid this problem? This situation can only be caused by calling doprnt with format_end set to some point inside a multibyte character (it's a pointer). I suppose that's the caller's fault and it's probably not up to doprnt to "fix" it. You would get the same effect by passing doprnt a format string that ends "inside" a multibyte char. This is slightly complicated by the fact that I think we want to truncate the output on a character boundary if we run out of output buffer, but if the format string is already truncated inside a multibyte character then we want to output everything that's there. Something like: { int charlen = BYTES_BY_CHAR_HEAD (fmtchar); src = fmt0; /* If the format string ends in the middle of a multibyte character we don't want to skip over the null byte. */ for (srclen = 1 ; *(src + srclen) != 0 && srclen < charlen ; srclen++); fmt = src + srclen; } As for the old code, as far as I can see it implicitly assumed the format string was always unibyte and do didn't do anything special if the buffer ran out in the middle of a multibyte character, but you can see that it took special care not to truncate a multibyte character in the other data, e.g. a curved quote or a non-format string (doit1). -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 29 05:28:11 2020 Received: (at 44349) by debbugs.gnu.org; 29 Nov 2020 10:28:11 +0000 Received: from localhost ([127.0.0.1]:49788 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjJwB-0000yv-Jp for submit@debbugs.gnu.org; Sun, 29 Nov 2020 05:28:11 -0500 Received: from quimby.gnus.org ([95.216.78.240]:51948) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjJw9-0000yj-U1 for 44349@debbugs.gnu.org; Sun, 29 Nov 2020 05:28:10 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=2PVvQyLeRJ3Gmb8HQv18PU4cLGNQdZpW+G8fr1fZoo0=; b=snzmhZN3FA/WbUlu5G6XnKGWic 8ossZQTPcvoxtPPmTaoJfUzIIWOSJ1myb7YNePR3ncvtCFUcv6DLeNwr3kfJ1fx99+bz77hl9owDo C6ia7U3Mtr6pekC5G9+6dZeeLfX4pJZCm3wqE5+ySptU6EJhEdrcsufwF3NyMU5OelXw=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kjJvz-0004PM-Ul; Sun, 29 Nov 2020 11:28:03 +0100 From: Lars Ingebrigtsen To: Alan Third Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> <835z5por4y.fsf@gnu.org> <20201128220645.GF26836@breton.holly.idiocy.org> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEWYX16GWlrXyL7/ //9u4OxpAAAAAWJLR0QDEQxM8gAAAAd0SU1FB+QLHQkrEYezq3MAAAGGSURBVCjPPZHBattAEIZn hRWoTq6Ie/ApFAphnkIJOfkkjMYUnXps9RSycUrYUxHJxaeVcMzqf8rOyEoEy+ynf/bfnRkiopWU jn4yoHtKpSLa4APKwv2awUn65H6oRAU5J9vzohWFilwh3C/om8JXSssaozp4hQeRBuPScQZalkth jAXFLcinRAZJuAUhFApxwW0KindPB31JDrcxKFSAfynZIPO4NBr0npgioFsHoG8ofGnAr2sg0obC /QaH56YDpTWFZI3Qc76XiomyDuCXf2QGlF2sLI+pOH4HzsdE9xe64xF4/n1ok9NAAyIjfcwPf7sT 6W3Ze0FAWNUUAR/shBmArxs/wfzFP67+BIyioIcw6NqLpsXBwOe4MYiDisPRpjClmYHjq1vQpkep QI39TeD9SrtTGyzhu7Oe2QJHLd+/2gt2Wg3axL/ZsHRGe27Zv+0M1OE72LeWJipf5ueRbCe4NkR2 FthP9Yg6oOfTVTGHPa9nUIf+vp5hih/K5JDPUFm0O/EfFb0JCzV+bpUAAAAldEVYdGRhdGU6Y3Jl YXRlADIwMjAtMTEtMjlUMDk6NDM6MTcrMDA6MDBiKL+MAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDIw LTExLTI5VDA5OjQzOjE3KzAwOjAwE3UHMAAAAABJRU5ErkJggg== X-Now-Playing: Etubom Rex Williams & His Nigerian Artistes's _Nigeria 70 (No Wahala: Highlife, Afro-Funk & Juju 1973-1987)_: "Psychedelic Shoes" Date: Sun, 29 Nov 2020 11:27:58 +0100 In-Reply-To: <20201128220645.GF26836@breton.holly.idiocy.org> (Alan Third's message of "Sat, 28 Nov 2020 22:06:45 +0000") Message-ID: <87a6v0h2z5.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Alan Third writes: >> Thanks! Can we add tests for this? > > I was wondering that. How do we add tests for internal C functions? For src/doprnt.c, the tests go in test/src/doprnt-tests.el etc. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, Eli Zaretskii , p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Alan Third writes: >> Thanks! Can we add tests for this? > > I was wondering that. How do we add tests for internal C functions? For src/doprnt.c, the tests go in test/src/doprnt-tests.el etc. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 29 10:10:25 2020 Received: (at 44349) by debbugs.gnu.org; 29 Nov 2020 15:10:25 +0000 Received: from localhost ([127.0.0.1]:52230 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjOLJ-0003vS-D6 for submit@debbugs.gnu.org; Sun, 29 Nov 2020 10:10:25 -0500 Received: from eggs.gnu.org ([209.51.188.92]:36016) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjOLG-0003v5-4H for 44349@debbugs.gnu.org; Sun, 29 Nov 2020 10:10:23 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:35062) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kjOLA-0001Oq-Su; Sun, 29 Nov 2020 10:10:16 -0500 Received: from [176.228.60.248] (port=1618 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kjOL7-0004Yy-FL; Sun, 29 Nov 2020 10:10:16 -0500 Date: Sun, 29 Nov 2020 17:10:03 +0200 Message-Id: <835z5omc6s.fsf@gnu.org> From: Eli Zaretskii To: Alan Third In-Reply-To: <20201128220645.GF26836@breton.holly.idiocy.org> (message from Alan Third on Sat, 28 Nov 2020 22:06:45 +0000) Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> <835z5por4y.fsf@gnu.org> <20201128220645.GF26836@breton.holly.idiocy.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Sat, 28 Nov 2020 22:06:45 +0000 > From: Alan Third > Cc: p.stephani2@gmail.com, 44349@debbugs.gnu.org > > > Thanks! Can we add tests for this? > > I was wondering that. How do we add tests for internal C functions? By calling Lisp functions which call them. But maybe it isn't possible in this case. Wait, isn't the use case which caused this bug report a suitable test for the change? > > Silently ignoring parts of input sounds ... unusual, so I wonder what > > would it take to avoid that. How did the old code avoid this problem? > > This situation can only be caused by calling doprnt with format_end > set to some point inside a multibyte character (it's a pointer). Ah, okay. In that case, I think ignoring the invalid sequence is OK, but let's document that in the function's commentary. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 29 12:16:49 2020 Received: (at 44349) by debbugs.gnu.org; 29 Nov 2020 17:16:49 +0000 Received: from localhost ([127.0.0.1]:52411 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQJc-0003FB-Pi for submit@debbugs.gnu.org; Sun, 29 Nov 2020 12:16:49 -0500 Received: from wilbur.contactoffice.com ([212.3.242.68]:34556) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQJb-0003Er-6T for 44349@debbugs.gnu.org; Sun, 29 Nov 2020 12:16:47 -0500 Received: from smtpauth2.co-bxl (smtpauth2.co-bxl [10.2.0.24]) by wilbur.contactoffice.com (Postfix) with ESMTP id 9B976D62; Sun, 29 Nov 2020 18:16:41 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1606670201; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:In-Reply-To; l=1621; bh=dLvoBxiulMlVsbBsMh+FxCVRtHjen5AMkEkcobkmjJA=; b=Jqusm3CHJvdRDCI5wK82o+aMtSqLaIf2xrNkzias/t2bmumyJWS0diSr0AfnqAGC 4joqf3ED+FAOP5AdcbRHdbzkTJmWwnP6Wd1V7BFCsO0WG8hZj6cas90PCFs4/YemAJX ErXD2n2HVhP4/vIvxjG+J7HXV90rP1Bza2N5UPDx7/YitwdTUZ09GovuZtBIapkj/Zs xhb1zIQpmZvvvQ1Yf5nxr9fLKqG/tGQBmcPzMSdaDCGgpLV2x3M0XmvkuOL9/GDZCbn qYKvIy/OIdw3Uzw4I0DW9kWV4+2H8ugEjSmfwpQZ2D06mVeT6MQF18dmNaL9tBQVk08 6A+60t+1Hw== Received: by smtp.mailfence.com with ESMTPA ; Sun, 29 Nov 2020 18:16:38 +0100 (CET) Received: by breton.holly.idiocy.org (Postfix, from userid 501) id ADB0A20269C9B9; Sun, 29 Nov 2020 17:16:23 +0000 (GMT) Date: Sun, 29 Nov 2020 17:16:23 +0000 From: Alan Third To: Eli Zaretskii Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame Message-ID: <20201129171623.GH26836@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Eli Zaretskii , 44349@debbugs.gnu.org, p.stephani2@gmail.com References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> <835z5por4y.fsf@gnu.org> <20201128220645.GF26836@breton.holly.idiocy.org> <835z5omc6s.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <835z5omc6s.fsf@gnu.org> X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.20 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sun, Nov 29, 2020 at 05:10:03PM +0200, Eli Zaretskii wrote: > > Date: Sat, 28 Nov 2020 22:06:45 +0000 > > From: Alan Third > > Cc: p.stephani2@gmail.com, 44349@debbugs.gnu.org > > > > > Thanks! Can we add tests for this? > > > > I was wondering that. How do we add tests for internal C functions? > > By calling Lisp functions which call them. But maybe it isn't > possible in this case. > > Wait, isn't the use case which caused this bug report a suitable test > for the change? It requires a frame to be resized with the mouse, we don't have a way of doing that from lisp. I can't see any way of using lisp functions to test doprnt, it's mostly used in formatting error messages and other small bits and pieces. > > > Silently ignoring parts of input sounds ... unusual, so I wonder what > > > would it take to avoid that. How did the old code avoid this problem? > > > > This situation can only be caused by calling doprnt with format_end > > set to some point inside a multibyte character (it's a pointer). > > Ah, okay. In that case, I think ignoring the invalid sequence is OK, > but let's document that in the function's commentary. I think, having thought about it more, I'd prefer to just pass through the malformed input. If we want to make sure that putting format_end in the middle of a multibyte character doesn't break anything I think we'd be better fixing doprnt_non_null_end to cut the string up neatly. format_end isn't currently used anywhere in Emacs, so I don't know if it's worth fixing, but I'll add a FIXME comment. -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 29 12:24:12 2020 Received: (at 44349) by debbugs.gnu.org; 29 Nov 2020 17:24:12 +0000 Received: from localhost ([127.0.0.1]:52424 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQQm-0003R9-6H for submit@debbugs.gnu.org; Sun, 29 Nov 2020 12:24:12 -0500 Received: from eggs.gnu.org ([209.51.188.92]:56144) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQQk-0003Qw-4P for 44349@debbugs.gnu.org; Sun, 29 Nov 2020 12:24:10 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:37068) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kjQQe-0006IB-It; Sun, 29 Nov 2020 12:24:04 -0500 Received: from [176.228.60.248] (port=2001 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kjQQc-0007b2-SJ; Sun, 29 Nov 2020 12:24:04 -0500 Date: Sun, 29 Nov 2020 19:23:53 +0200 Message-Id: <83k0u4krfa.fsf@gnu.org> From: Eli Zaretskii To: Alan Third In-Reply-To: <20201129171623.GH26836@breton.holly.idiocy.org> (message from Alan Third on Sun, 29 Nov 2020 17:16:23 +0000) Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> <835z5por4y.fsf@gnu.org> <20201128220645.GF26836@breton.holly.idiocy.org> <835z5omc6s.fsf@gnu.org> <20201129171623.GH26836@breton.holly.idiocy.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Sun, 29 Nov 2020 17:16:23 +0000 > From: Alan Third > Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com > > > Ah, okay. In that case, I think ignoring the invalid sequence is OK, > > but let's document that in the function's commentary. > > I think, having thought about it more, I'd prefer to just pass through > the malformed input. If we want to make sure that putting format_end > in the middle of a multibyte character doesn't break anything I think > we'd be better fixing doprnt_non_null_end to cut the string up neatly. Anything that avoids a crash is fine in this case, thanks. > format_end isn't currently used anywhere in Emacs, so I don't know if > it's worth fixing, but I'll add a FIXME comment. TIA. From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 29 12:43:37 2020 Received: (at 44349) by debbugs.gnu.org; 29 Nov 2020 17:43:37 +0000 Received: from localhost ([127.0.0.1]:52509 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQjZ-00041C-HF for submit@debbugs.gnu.org; Sun, 29 Nov 2020 12:43:37 -0500 Received: from wilbur.contactoffice.com ([212.3.242.68]:35394) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kjQjX-00040v-TH; Sun, 29 Nov 2020 12:43:36 -0500 Received: from smtpauth1.co-bxl (smtpauth1.co-bxl [10.2.0.15]) by wilbur.contactoffice.com (Postfix) with ESMTP id 87961DA5; Sun, 29 Nov 2020 18:43:29 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1606671809; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:In-Reply-To; l=942; bh=fTZqY1E+krVWrphpz2+7Jf/kgfKXQ8npLEtbTEtL+os=; b=Jjs+Q/5cQDNCbksJD2Y6ZxZ5/8sUW7yvWX0FkSEk1ScVH9u/lpnNIW7EPeTx1FDg niWP0eEYyrva1n3OXrRtJiVZENLwb0vyp1epDdCVbwRQ5XoEzZMfyP3dK7hc0iHrAn2 svlKC+uuD/sdSKDIJ4XMjjgD8KK9kTKoSTxi9di07gFZnjaq5Q3nJvGDSC2SoFWyfOo 8pZoq88Q+oEbWV2KHuio0oDB/Fur4uSckjB9OgO+ngWUNKHSstWj13EqbQzU3zuHuIm EWzZaDP52lvpw7NFq0sqQUlvrQEHOZZdplGkepx89/C/l6we0UzwB8BPsTAp5BYqOg/ avVUu23w/Q== Received: by smtp.mailfence.com with ESMTPA ; Sun, 29 Nov 2020 18:43:27 +0100 (CET) Received: by breton.holly.idiocy.org (Postfix, from userid 501) id 3520320269E4D8; Sun, 29 Nov 2020 17:43:25 +0000 (GMT) Date: Sun, 29 Nov 2020 17:43:25 +0000 From: Alan Third To: Eli Zaretskii Subject: Re: bug#44349: 28.0.50; Assertion failure on macOS when resizing frame Message-ID: <20201129174325.GI26836@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Eli Zaretskii , 44349@debbugs.gnu.org, p.stephani2@gmail.com References: <83eelegxq6.fsf@gnu.org> <83a6w2gwxz.fsf@gnu.org> <20201127222429.GD26836@breton.holly.idiocy.org> <835z5por4y.fsf@gnu.org> <20201128220645.GF26836@breton.holly.idiocy.org> <835z5omc6s.fsf@gnu.org> <20201129171623.GH26836@breton.holly.idiocy.org> <83k0u4krfa.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <83k0u4krfa.fsf@gnu.org> X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.21 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44349 Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) unmerge 44850 close 44349 28.1 quit On Sun, Nov 29, 2020 at 07:23:53PM +0200, Eli Zaretskii wrote: > > Date: Sun, 29 Nov 2020 17:16:23 +0000 > > From: Alan Third > > Cc: 44349@debbugs.gnu.org, p.stephani2@gmail.com > > > > > Ah, okay. In that case, I think ignoring the invalid sequence is OK, > > > but let's document that in the function's commentary. > > > > I think, having thought about it more, I'd prefer to just pass through > > the malformed input. If we want to make sure that putting format_end > > in the middle of a multibyte character doesn't break anything I think > > we'd be better fixing doprnt_non_null_end to cut the string up neatly. > > Anything that avoids a crash is fine in this case, thanks. > > > format_end isn't currently used anywhere in Emacs, so I don't know if > > it's worth fixing, but I'll add a FIXME comment. > > TIA. Done and pushed. Thanks. -- Alan Third From unknown Sun Aug 10 16:49:22 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 28 Dec 2020 12:24:09 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator