As with many countries/states, the working definition of a knife that can be construed as a weapon is generally set at 4 inches:
First, subdivision (b) makes it illegal to carry a knife with a blade length of four inches or more...
There are exceptions both ways to this: something with a smaller blade can still be considered illegal if the intended purpose is to wield the object in a way that weaponizes and is to be used in a harmful manner, and there are any number of subdivisions that make it legal for blades (of larger length) to be legally carried upon a persons.
These are enveloped in a wide spectrum, but each incident is to be assessed in isolation and at the discretion of the individual officers concerned. As with most law, the defining factor in each case comes down to intent of purpose...
The provisions of subdivisions b and c of this section shall not apply to (1) persons in the military service of the state of New York when duly authorized to carry or display knives pursuant to regulations issued by the chief of staff to the governor; (2) police officers and peace officers as defined in the criminal procedure law; (3) participants in special events when authorized by the police commissioner; (4) persons in the military or other service of the United States, in pursuit of official duty authorized by federal law; (5) emergency medical technicians or voluntary or paid ambulance drivers while engaged in the performance of their duties; or (6) any person displaying or in possession of a knife otherwise in violation of this section when such knife (a) is being used for or transported immediately to or from a place where it is used for hunting, fishing, camping, hiking, picnicking or any employment, trade or occupation customarily requiring the use of such knife; or (b) is displayed or carried by a member of a theatrical group, drill team, military or para-military unit or veterans organization, to, from, or during a meeting, parade or other performance or practice for such event, which customarily requires the carrying of such knife; or (c) is being transported directly to or from a place of purchase, sharpening or repair, packaged in such a manner as not to allow easy access to such knife while it is transported; or (d) is displayed or carried by a duly enrolled member of the Boy or Girl Scouts of America or a similar organization or society and such display or possession is necessary to participate in the activities of such organization or society.
If an officer deems the intention of carrying what would otherwise be an illegal weapon as falling within one of these subcategories, they are able to 'overlook' the incident.
Mick Dundee could have claimed he was using the knife for hunting (Central Park, perhaps!... it is full of bears, afterall), but its more likely that the officer (in an incredulous moment of sensitivity) chalked this incident up to a cultural mis-understanding and simply confiscated the blade temporarily whilst he escorted him back to his hotel.
Giving the blade back to Dundee is, however, wildly unlikely: if Mick was to commit an act of assault following this, the officer would have been considered an accessory to the act.
In summary: it was indeed illegal for Mick to be carrying the blade in NYC, but the officer appears to have exorcised his right to discretion.
Possible, but given the reputation of the NYPD, the odds are astronomically improbable that such sensitivity would be invoked in reality. The knife would at least have been confiscated.
Fun Fact: In the UK, a legal paradox has been deliberately created to give police officers more opportunities for arrest in carrying bladed articles in public: basically, a blanket ban on carrying any blade for any reason. Even if you've just purchased a knife for legitimate purposes, as soon as the leave the vendors private premises (even to walk to your car, which might be less than 4 feet away from the door) you are breaking the law and can be arrested. Such is the vulnerability of operating under an uncodified constitution.