bug-1906021: strip whitespace from Android_CPU_ABI2 and other string fields #6824
+17
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This changes the
CopyFromRawCrashRule
to strip the right side of string field values. I haven't seen anything in crash reports so far where whitespace at the end of a crash annotation value is significant so I think this is safe.If it turns out not to be safe, we can extend
CopyFromRawCrashRule
to look at a "transforms" field to glean how it should transform the value after copying it. This would be helpful for the increasing number of fields that are comma or semi-colon delimited, too.To test:
Android_CPU_ABI2
value in the raw crash--it has\r\n
at the endandroid_cpu_abi2
value in the processed crash--it does not have\r\n
at the end