-
-
Notifications
You must be signed in to change notification settings - Fork 308
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: keep multi-line header value newlines verbatim
Previously they were normalized to \n which made round-trips degenerate information. It's notable that we explicitly do NOT normalize the newline at the very last line of the multi-line header as its part of that line, even though it's also relevant to make the header field valid. The reason is that these *can* also be written with \r\n, and we don't want to degenerate that information.
- Loading branch information
Showing
9 changed files
with
53 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -147,7 +147,7 @@ fn signed() -> crate::Result { | |
committer: signature(1592391367), | ||
encoding: None, | ||
message: b"update tasks\n".as_bstr(), | ||
extra_headers: vec![(b"gpgsig".as_bstr(), b"-----BEGIN PGP SIGNATURE-----\n\niQEzBAABCAAdFiEEdjYp/sh4j8NRKLX27gKdHl60AwAFAl7p9tgACgkQ7gKdHl60\nAwBpegf+KQciv9AOIN7+yPmowecGxBnSfpKWTDzFxnyGR8dq63SpWT8WEKG5mf3a\nG6iUqpsDWaMHlzihaMKRvgRpZxFRbjnNPFBj6F4RRqfE+5R7k6DRSLUV5PqnsdSH\nuccfIDWi1imhsm7AaP5trwl1t+83U2JhHqPcPVFLMODYwWeO6NLR/JCzGSTQRa8t\nRgaVMKI19O/fge5OT5Ua8D47VKEhsJX0LfmkP5RfZQ8JJvNd40TupqKRdlv0sAzP\nya7NXkSHXCavHNR6kA+KpWxn900UoGK8/IDlwU6MeOkpPVawb3NFMqnc7KJDaC2p\nSMzpuEG8LTrCx2YSpHNLqHyzvQ1CZA==\n=5ITV\n-----END PGP SIGNATURE-----".as_bstr().into())] | ||
extra_headers: vec![(b"gpgsig".as_bstr(), b"-----BEGIN PGP SIGNATURE-----\n\niQEzBAABCAAdFiEEdjYp/sh4j8NRKLX27gKdHl60AwAFAl7p9tgACgkQ7gKdHl60\nAwBpegf+KQciv9AOIN7+yPmowecGxBnSfpKWTDzFxnyGR8dq63SpWT8WEKG5mf3a\nG6iUqpsDWaMHlzihaMKRvgRpZxFRbjnNPFBj6F4RRqfE+5R7k6DRSLUV5PqnsdSH\nuccfIDWi1imhsm7AaP5trwl1t+83U2JhHqPcPVFLMODYwWeO6NLR/JCzGSTQRa8t\nRgaVMKI19O/fge5OT5Ua8D47VKEhsJX0LfmkP5RfZQ8JJvNd40TupqKRdlv0sAzP\nya7NXkSHXCavHNR6kA+KpWxn900UoGK8/IDlwU6MeOkpPVawb3NFMqnc7KJDaC2p\nSMzpuEG8LTrCx2YSpHNLqHyzvQ1CZA==\n=5ITV\n-----END PGP SIGNATURE-----\n".as_bstr().into())] | ||
} | ||
); | ||
Ok(()) | ||
|
@@ -271,7 +271,7 @@ instead of depending directly on the lower-level crates. | |
Signed-off-by: Sebastian Thiel <[email protected]> | ||
Signed-off-by: Kim Altintop <[email protected]>" | ||
.as_bstr(), | ||
extra_headers: vec![(b"gpgsig".as_bstr(), b"-----BEGIN PGP SIGNATURE-----\n\niHUEABYIAB0WIQSuZwcGWSQItmusNgR5URpSUCnwXQUCYT7xpAAKCRB5URpSUCnw\nXWB3AP9q323HlxnI8MyqszNOeYDwa7Y3yEZaUM2y/IRjz+z4YQEAq0yr1Syt3mrK\nOSFCqL2vDm3uStP+vF31f6FnzayhNg0=\n=Mhpp\n-----END PGP SIGNATURE-----".as_bstr().into())] | ||
extra_headers: vec![(b"gpgsig".as_bstr(), b"-----BEGIN PGP SIGNATURE-----\n\niHUEABYIAB0WIQSuZwcGWSQItmusNgR5URpSUCnwXQUCYT7xpAAKCRB5URpSUCnw\nXWB3AP9q323HlxnI8MyqszNOeYDwa7Y3yEZaUM2y/IRjz+z4YQEAq0yr1Syt3mrK\nOSFCqL2vDm3uStP+vF31f6FnzayhNg0=\n=Mhpp\n-----END PGP SIGNATURE-----\n".as_bstr().into())] | ||
} | ||
); | ||
let message = commit.message(); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# assure newlines aren't butchered as they matter for testing | ||
**/*.txt text crlf=input eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,17 +2,17 @@ tree de33f909dd559dd60753264ccf9e80183a32c9cc | |
parent 2305aad7ac23331e75465eccf425f899fa53a8d8 | ||
author Brezak <[email protected]> 1724180029 +0200 | ||
committer Brezak <[email protected]> 1728251787 +0200 | ||
gpgsig -----BEGIN PGP SIGNATURE----- | ||
iQEzBAABCAAdFiEE6+MMXTYlBWl/3EAJyziR4rEnnXwFAmcDB4sACgkQyziR4rEn | ||
nXy8owf9EkHTtmxUKhXiZ8ThGlpqwzcUaaYOBSX6Pmwacz+mqsA7fwLN/AxyN/Wv | ||
d7zVhCYX01aZi7lutN4rVa08S9ZoXeZOBHm1u2YtrtETcjiBpVIVt33spkLendvB | ||
1C5UyuVhZ4m8bHG5A3kmJlg0Mf9cwKvNTZiozb+lG79p1b3rc8PJHilHdAMmaUkb | ||
58/7dUXM1B/LLd9p4IyJdLVA0jZmAagm+akiH/A1lji7zSvLJqhr1xOlD6L/K/Ao | ||
TM6Kk0i2+eido5vaoutUFuKx+u4j4OtA3lDohvmu36RwyZbfa3OSAg+TWChgYBc/ | ||
ctOcWsB0EKL3XKz7X8Sw2EIS1Fcd4w== | ||
=aZq+ | ||
-----END PGP SIGNATURE----- | ||
gpgsig -----BEGIN PGP SIGNATURE----- | ||
|
||
iQEzBAABCAAdFiEE6+MMXTYlBWl/3EAJyziR4rEnnXwFAmcDB4sACgkQyziR4rEn | ||
nXy8owf9EkHTtmxUKhXiZ8ThGlpqwzcUaaYOBSX6Pmwacz+mqsA7fwLN/AxyN/Wv | ||
d7zVhCYX01aZi7lutN4rVa08S9ZoXeZOBHm1u2YtrtETcjiBpVIVt33spkLendvB | ||
1C5UyuVhZ4m8bHG5A3kmJlg0Mf9cwKvNTZiozb+lG79p1b3rc8PJHilHdAMmaUkb | ||
58/7dUXM1B/LLd9p4IyJdLVA0jZmAagm+akiH/A1lji7zSvLJqhr1xOlD6L/K/Ao | ||
TM6Kk0i2+eido5vaoutUFuKx+u4j4OtA3lDohvmu36RwyZbfa3OSAg+TWChgYBc/ | ||
ctOcWsB0EKL3XKz7X8Sw2EIS1Fcd4w== | ||
=aZq+ | ||
-----END PGP SIGNATURE----- | ||
|
||
|
||
Check that `#[pointee]` is applied only to generic arguments |