GPSBabel / gpsbabel

GPSBabel: convert, manipulate, and transfer data from GPS programs or GPS receivers. Open Source and supported on MacOS, Windows, Linux, and more. Pointy clicky GUI or a command line version...
https://www.gpsbabel.org
GNU General Public License v2.0
470 stars 125 forks source link

fix leak in jeeps serial comm on posix. #1223

Closed tsteven4 closed 9 months ago

tsteven4 commented 9 months ago

This resolves #1221

I have tested this with a GPS12, "vtesto -l -j vg.log sgt.test", and: gpsbabel -D3 -i garmin -f /dev/ttyS0 gpsbabel -D3 -i gpx -f w.gpx -o garmin -F /dev/ttyS0

both operations succeeded and no leaks were detected.

tsteven4 commented 9 months ago

thanks @tdhoward for COMpipe.

robertlipe commented 9 months ago

I used to build serial drivers (and hardware) professionally. We were dealing with things that werent really a 16450 running on a Real Computer but virtualizing down to a 16450 in DOS so that Procomm and Kermit and things that wanted to do outb()'s on 0x3f8 would actually go through ISA shared memory commands, be read by one processor that packetetized that and generated sync packets, then shipped them over potentially a modem or even an SDLC connection, then get picked off the wire and command (alien) uarts on the other side of all that to do their bidding. It was a beautiful series of hacks when it worked ... and a hell of a train wreck when it didn't.

So of course I approve the PR, but I have a warm feeling about that glorious testing process. Nicely done!