Age | Commit message (Collapse) | Author | Files | Lines |
|
mailbox format requires that lines starting with 'From ' in the mail body
are escaped. That's usually done as '>From '.
Some mailbox generators including patchwork fail to do that which confuses
the python mailbox parser as it considers a 'From ' line in the mail body
as start of the next message.
Work around it by parsing the binary file content of the mailbox manually
and by applying heuristics to distinguish between a 'From ' line in the
body and a valid unixfrom line which starts a new message.
Reported-by: Alexei Starovoitov <alexei.starovoitov@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Stripping Cc lists from the mailheader also causes to lose the Cc: list in
the mail body around the SOB line. Add an option to collect that
independently.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
New lines in Message-Id headers are not handled correctly.
Strip any whitespace from the message id after retrieving it. The same
applies to References and In-Reply-To headers.
Reported-by: Alexei Starovoitov <alexei.starovoitov@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Deal with asymetric '[' brackets correctly.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Malformed Cc: and To: headers cause exceptions. Handle them gracefully.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Currently Reviewed-and-tested-by tags are ignored. Pick them up in the same way
as Reported-and-tested-by is handled.
Signed-off-by: Kurt Kanzenbach <kurt@kmk-computers.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Another infrequently used tag missing.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Packaging information depends on a proper versioning scheme. The version
information by now is hardcoded in the mb2q tool. Split out the version
information and provide the version for packaging tools.
Signed-off-by: Benedikt Spranger <b.spranger@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
The Python ecosystem provides mechanism to maintain proper information
for installation and packaging. Provide these informations.
Signed-off-by: Benedikt Spranger <b.spranger@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Debian buster only has python-yaml v3.13 currently. That version does not
include yaml.FullLoader.
Use the SafeLoader.
Signed-off-by: Torben Hohn <torben.hohn@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
The Co-developed-by is missing in the tag ordering list. Add it.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Notmuch provides the messages in a thread in reverse order, except for the
message which is the first one in a thread. This causes the patch ordering
in the resulting patch queue to be reverse.
Insert the mails into the list after thread starting message instead of
queueing them at the end.
Reported-by: Kurt Kanzenbach <kurt@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Be lazy and treat the inbox argument depending on the type. If it's a file,
assume mailbox, if it's a directory assume maildir.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Using a stale variable for comparison instead of the actual iterator does
not work well.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Fix the following mb2q issue on startup:
$ ./mb2q ./t.mbox
./mb2q:653: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated,
as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full
details.
cfg = yaml.load(open(os.path.expanduser(args.config)))
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Otherwise the decoder fails to handle especially asian character sets.
Reported-by: Bjorn Helgaas <helgaas@kernel.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
A discard line '--\n' was obviously not detected as the code was looking
for '---'.
Handle it by making the decision whether the posttag area starts by
checking whether the current line is past the last tag seen in the
text.
Reported-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Allow other p1 prefixes than 'a/'
Reported-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
The code only checks whether a patch file exists already, but it does not
handle the case when the same subject is there for two mails, which can
happen when there is a V$N+1 reply in the thread.
While patches which lack a SOB are correctly detected, the code fails later
because is assumes that there is always a SOB.
Fixup both.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Reported-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Add a configuration option which allows to add mail addresses which are
never dropped from the Cc list, e.g. stable@vger.kernel.org.
Move the committer SOB (if not placed at the end) right after the last SOB
in the chain.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
|
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|