diff --git a/src/dbginfo/dbginfo.c b/src/dbginfo/dbginfo.c index 16bc9d9de..05951f6c6 100644 --- a/src/dbginfo/dbginfo.c +++ b/src/dbginfo/dbginfo.c @@ -2933,7 +2933,7 @@ static void ParseCSym (InputData* D) } /* Symbol only valid if storage class not auto */ - if (((InfoBits & ibSymId) != 0) != (SC != CC65_CSYM_AUTO)) { + if (((InfoBits & ibSymId) != 0) && (SC == CC65_CSYM_AUTO)) { ParseError (D, CC65_ERROR, "Only non auto symbols can have a symbol attached"); goto ErrorExit; }