Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2875014
D25567.1736968299.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
788 B
Referenced Files
None
Subscribers
None
D25567.1736968299.diff
View Options
diff --git a/src/infrastructure/export/format/PhabricatorCSVExportFormat.php b/src/infrastructure/export/format/PhabricatorCSVExportFormat.php
--- a/src/infrastructure/export/format/PhabricatorCSVExportFormat.php
+++ b/src/infrastructure/export/format/PhabricatorCSVExportFormat.php
@@ -48,11 +48,11 @@
// like it might be too tempting for Excel to ignore, mangle the value
// to dissuade remote code execution. See T12800.
- if (preg_match('/^\s*[+=@-]/', $value)) {
+ if ($value && preg_match('/^\s*[+=@-]/', $value)) {
$value = '(!) '.$value;
}
- if (preg_match('/\s|,|\"/', $value)) {
+ if ($value && preg_match('/\s|,|\"/', $value)) {
$value = str_replace('"', '""', $value);
$value = '"'.$value.'"';
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jan 15, 19:11 (2 w, 19 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1109338
Default Alt Text
D25567.1736968299.diff (788 B)
Attached To
Mode
D25567: Fix PHP 8.1 "preg_match(null)" exception exporting task list to CSV
Attached
Detach File
Event Timeline
Log In to Comment