From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.bugs Subject: bug#13879: Change src/msdos.c from raw-text to ASCII Date: Tue, 05 Mar 2013 09:43:07 -0800 Message-ID: <51362EAB.6080905@cs.ucla.edu> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------080200050500030703030800" X-Trace: ger.gmane.org 1362505458 19970 80.91.229.3 (5 Mar 2013 17:44:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 5 Mar 2013 17:44:18 +0000 (UTC) To: 13879@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Mar 05 18:44:42 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UCvur-0008Hl-Ee for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Mar 2013 18:44:41 +0100 Original-Received: from localhost ([::1]:33042 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCvuV-0006XH-W5 for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Mar 2013 12:44:19 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:41825) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCvtv-0005jW-OB for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 12:43:45 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UCvtu-0004T6-3a for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 12:43:43 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:56881) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCvtu-0004T1-11 for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 12:43:42 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1UCvuE-0007Jh-TC for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 12:44:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Paul Eggert Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 05 Mar 2013 17:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 13879 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.136250542428090 (code B ref -1); Tue, 05 Mar 2013 17:44:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 5 Mar 2013 17:43:44 +0000 Original-Received: from localhost ([127.0.0.1]:60990 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UCvtv-0007J0-VV for submit@debbugs.gnu.org; Tue, 05 Mar 2013 12:43:44 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:58573) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UCvtu-0007Io-PC for submit@debbugs.gnu.org; Tue, 05 Mar 2013 12:43:43 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UCvtT-0004OE-CU for submit@debbugs.gnu.org; Tue, 05 Mar 2013 12:43:16 -0500 Original-Received: from lists.gnu.org ([208.118.235.17]:39976) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCvtT-0004OA-9i for submit@debbugs.gnu.org; Tue, 05 Mar 2013 12:43:15 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:41688) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCvtR-0004ye-Gb for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 12:43:15 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UCvtO-0004N4-9W for bug-gnu-emacs@gnu.org; Tue, 05 Mar 2013 12:43:13 -0500 Original-Received: from smtp.cs.ucla.edu ([131.179.128.62]:51339) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCvtO-0004Ms-1F; Tue, 05 Mar 2013 12:43:10 -0500 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp.cs.ucla.edu (Postfix) with ESMTP id 53811A6007C; Tue, 5 Mar 2013 09:43:09 -0800 (PST) X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu Original-Received: from smtp.cs.ucla.edu ([127.0.0.1]) by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XiQfeDhSPi+w; Tue, 5 Mar 2013 09:43:08 -0800 (PST) Original-Received: from penguin.cs.ucla.edu (Penguin.CS.UCLA.EDU [131.179.64.200]) by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 70D9AA60090; Tue, 5 Mar 2013 09:43:08 -0800 (PST) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130219 Thunderbird/17.0.3 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 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.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:72121 Archived-At: This is a multi-part message in MIME format. --------------080200050500030703030800 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Tags: patch In my attempt to make the Emacs sources UTF-8-safe, I ran across src/msdos.c, which is currently raw-text because it has string literals containing bytes with the top bit set. There's an easy way to make this ASCII, e.g., use the string literal "\375" rather than "X" (where X is the actual byte with octal code 375). Attached is a proposed patch. I'm CC'ing this to Eli since this affects the MS-DOS port. --------------080200050500030703030800 Content-Type: text/plain; charset=us-ascii; name="msdos.txt" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="msdos.txt" PT09IG1vZGlmaWVkIGZpbGUgJ3NyYy9tc2Rvcy5jJwotLS0gc3JjL21zZG9zLmMJMjAxMy0w Mi0xNyAxNjo0OToyNyArMDAwMAorKysgc3JjL21zZG9zLmMJMjAxMy0wMy0wNSAxNzozODoy MiArMDAwMApAQCAtMSw0ICsxLDQgQEAKLS8qIE1TLURPUyBzcGVjaWZpYyBDIHV0aWxpdGll cy4gICAgICAgICAgLSotIGNvZGluZzogcmF3LXRleHQgLSotCisvKiBNUy1ET1Mgc3BlY2lm aWMgQyB1dGlsaXRpZXMuICAgICAgICAgIC0qLSBjb2Rpbmc6IHVzLWFzY2lpIC0qLQogCiBD b3B5cmlnaHQgKEMpIDE5OTMtMTk5NywgMTk5OS0yMDEzIEZyZWUgU29mdHdhcmUgRm91bmRh dGlvbiwgSW5jLgogCkBAIC0xOTc2LDExICsxOTc2LDExIEBACiBzdGF0aWMgc3RydWN0IGRv c19rZXlib2FyZF9tYXAgZnJfa2V5Ym9hcmQgPSB7CiAvKiAwICAgICAgICAgMSAgICAgICAg IDIgICAgICAgICAzICAgICAgICAgNCAgICAgICAgIDUgICAgICAqLwogLyogMDEyIDM0NTY3 ODkwMTIzNDU2Nzg5MDEyMzQ1Njc4OTAxMjM0NTY3ODkwMTIzNDU2Nzg5MDEyMzQgKi8KLSAg Iv0mglwiLCgtil+AhSk9ICBhemVydHl1aW9wXiQgICBxc2RmZ2hqa2xtlyogICB3eG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