Missing warning for unused code

Hal Murray halmurray at sonic.net
Wed Aug 19 01:57:34 UTC 2026


I fatfingered something and ended up with this code:
                    default:
                        snprintf(errbuf, errlng,
                                "Received strange type: T=%d, C=%d, L=%d",
                                type, critical, length);
                        return false;
                        buf->next += length;
                        buf->left -= length;
                        break;

The compiler didn't complain.  I expect a warning.

I just poked in the man page.  There is -Wunused which turns on a bunch of 
-Wunused-xxx, but none of the xxxs are code.  Am I missing something?

-- 
These are my opinions.  I hate spam.





More information about the devel mailing list