telehash/telehash-c

review all packet owner cleanup

Closed this issue · 7 comments

Most places packets are being created and passed around are not being free'd yet, needs a full review and consistent owner-free pattern applied.

I'd love to find a tool to help do leak detection, but yeah since I'm currently using telehash-c for embedded/arduino then tools like this don't work so well :)

I recommend adding this project to coverity. Coverity is free (as in beer) for open-source projects and is very good at finding leaks. It's hands-down the best static-analysis tool I've use and one really should use a static-analysis tool when writing C these days.

I'm in coverity often enough and I can add it there. I've added a few projects so I'm somewhat familiar with the process. It will also identify many other C coding errors.

bachp commented

Agree we should take advantages of the coverity findings.
@jbdatko it would be nice if you could setup the scan.

Telehash-c was already registered with coverity. Perhaps @quartzjer did this? Anyway, it doesn't look like a build was every submitted so once the project maintainer approves me I can submit a build.

So indeed @quartzjer is the mysterious admin of this coverity scan project, but it appears that I have to be an "administrator" in the coverity system for telehash-c to submit builds.

Jer, can you make me an admin and I'll upload a build to coverity?

Ouch... 34 errors on the initial build.

I'll make a separate GitHub issue that is a coverity work-off.

all major packet flows are now clean, cs2a (and maybe 3a) could leak yet, but I'm closing this general issue and can open specific ones as more leaks found