Closed (fixed)
Project:
Adform
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 May 2017 at 08:50 UTC
Updated:
24 May 2017 at 09:49 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
sutharsan commentedComment #3
sutharsan commentedComment #4
xen commentedHeh, funnily enough the issue was caused by a patch that tried to fix an issue that was probably caused by \r in the input.
But i think the issue can be fixed lighter, please try the attached patch.
Comment #5
sutharsan commentedPatch works fine.
However, I would not change the Hostnames separator behaviour, "... seperated by space or on seperate lines." (or not in this patch). When saving the hostnames, the space separator is replaced by a new line.
Comment #6
xen commentedOK, stepping back a minute. Have you actually run into issues with \r? No modern OS uses only \r for newline, and the trimming of the exploded lines in the original code should strip out extra \r making special handling unnecessary.
Try the attached patch which reverts the original "fix", especially if it handles an empty mapping OK.
Comment #7
sutharsan commentedNo, I have not ran into problems with \r. Apparently I'm repeating an old pattern, also in core (e.g. RequestPath) only \n is used.
The reason I worked on this code was to fix the problem that adform_mappings is stored as string (and not as empty array) when no mappings are entered.
RTBC again, thanks.
Comment #8
xen commentedFix committed. Release 1.2 should be available shortly.