Wow...I didn't know this. My 12 yr old son was carrying a lock blade when we visited nyc 4 yrs ago...he had to empty his pockets to pass through a metal detector to enter the 9/11 memorial (security theater, but that's a different discussion). The security officer didn't say anything about it.
Then the security officer either wasn't paying attention, didn't realize it was a locked blade knife, was not looking for small knives, or, most likely, wasn't properly trained. Security guards at such buildings are not police officers - they are private security.
The NYPD doesn't guard office buildings as a rule. Most of them have their own security if they elect to have metal detectors. Of late I have not entered an office building in NYC that did not have a metal detector and private security. Admittedly, I am routinely in NYC due to family and we have various reasons to enter such buildings. It's very annoying to have to leave ANY knife at home or in a car.
That said, you have to realize that since the guard was not a police officer even if he KNEW that the knife was illegal he certainly did not have a police officer's obligation to do anything about it.
Being caught having an "illegal" pocket knife on your person probably wouldn't have any consequences unless you were caught performing some other criminal act.
That would not be correct. NYPD LEOs
WILL arrest you if they catch you with an "illegal knife" so if you plan to carry a knife in NYC make sure that (1) it is very difficult to open/takes two hands so the police cannot claim that it is a gravity knife and (2) that it does not lock back. My choice for my last trip was a Swiss Army knife and an Opinel.
I do have a small, lockback knife that I occasionally carry in NYC but my defense to that is that I bought it in NYC so how can it be illegal to possess it there? I couldn't find it last month so I took the Opinel. And my defense could fail - I know that!
If you do anything hinky then the knife makes the arrest easy but I caution everyone to NOT carry a locking blade, easy to open pocket knife and NEVER NEVER NEVER use a clip to attach it to a pocket where it is visible.