lib: Remove dead code and add missing semicolons

... ocd.