A surprising piece of code found in some program. While usually not wrong, it tends to vary from crufty to bletcherous, and has lain undiscovered only because it was functionally correct, however horrible it is. Used sarcastically, because what is found is anything *but* treasure. Buried treasure almost always needs to be dug up and removed. "I just found that the scheduler sorts its queue using bubble sort! Buried treasure!"
Try this search on Wikipedia, OneLook, Google
Nearby terms: burble « Bureau International des Poids et Mesures « Burge's Language « buried treasure » burn-in » burn-in period » Burroughs Corporation