unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* allow EWW to upload files ending in newline
@ 2023-07-26 22:11 ozzloy
  2023-08-29  0:35 ` ozzloy
  0 siblings, 1 reply; 2+ messages in thread
From: ozzloy @ 2023-07-26 22:11 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 396 bytes --]

EWW has a bug where files uploaded ending in newline have the final
newline chomped.

I have fixed the bug and submitted a patch.  I would be greatful if
an expert on gnus and/or eww could review the patch attached to the
following message.

https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63941#50

also viewable in browser here

https://git.sr.ht/~ozzloy/emacs/commit/emacs-29-bug-63941

Thanks!

[-- Attachment #2: Type: text/html, Size: 603 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: allow EWW to upload files ending in newline
  2023-07-26 22:11 allow EWW to upload files ending in newline ozzloy
@ 2023-08-29  0:35 ` ozzloy
  0 siblings, 0 replies; 2+ messages in thread
From: ozzloy @ 2023-08-29  0:35 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 895 bytes --]

I would appreciate it if an expert on gnus and/or eww could
review the patch attached to the following message.

https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63941#53

here's the bug fixing part of the diff inline for ease of
reference,

---
diff --git a/lisp/gnus/mm-url.el b/lisp/gnus/mm-url.el
index 11847a79f17..5b68b25ec2e 100644
--- a/lisp/gnus/mm-url.el
+++ b/lisp/gnus/mm-url.el
@@ -433,13 +433,12 @@ mm-url-encode-multipart-form-data
       (insert (number-to-string filedata))))))
  ((equal name "submit")
   (insert
-   "Content-Disposition: form-data; name=\"submit\"\r\n\r\nSubmit\r\n"))
+   "Content-Disposition: form-data; name=\"submit\"\r\n\r\nSubmit"))
  (t
   (insert (format "Content-Disposition: form-data; name=%S\r\n\r\n"
   name))
   (insert value)))
- (unless (bolp)
-  (insert "\r\n"))))
+ (insert "\r\n")))
     (insert "--" boundary "--\r\n")
     (buffer-string)))

[-- Attachment #2: Type: text/html, Size: 1210 bytes --]

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-08-29  0:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-26 22:11 allow EWW to upload files ending in newline ozzloy
2023-08-29  0:35 ` ozzloy

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).