Opened 5 years ago
Closed 4 years ago
#1624 closed enhancement (fixed)
[PATCH] use consistent line endings in GpxWriter
| Reported by: | h-a-l-9000@… | Owned by: | framm |
|---|---|---|---|
| Priority: | trivial | Component: | Core |
| Version: | Keywords: | ||
| Cc: |
Description
When opening a gpx file written by GpxWriter with i.e. Windows Notepad the formatting is broken. The small patch makes them consistent.
Attachments (1)
Change History (5)
Changed 5 years ago by h-a-l-9000@…
comment:1 Changed 5 years ago by Henry Loenwind
- Priority changed from minor to trivial
- Summary changed from Patch: use consistent line endings in GpxWriter to [PATCH] use consistent line endings in GpxWriter
- Type changed from defect to enhancement
comment:2 follow-up: ↓ 3 Changed 5 years ago by anonymous
comment:3 in reply to: ↑ 2 Changed 5 years ago by h-a-l-9000@…
Replying to anonymous:
this will save \r\n on windows and \n on Linux (different on MacOS)
It's the desired behaviour?
Should always write \n or write platform specific line-ending character?
Currently there are both println(...) and print("\n") used for writing the file. The patch is supposed to unify it.
The parsers shouldn't bother either way, it's just a cosmetic error in the rare case that a human opens such a file.
comment:4 Changed 4 years ago by stoecker
- Resolution set to fixed
- Status changed from new to closed
Fixed in r1164.



this will save \r\n on windows and \n on Linux (different on MacOS)
It's the desired behaviour?
Should always write \n or write platform specific line-ending character?