Yeah, don't eat if it's just out of boredom. Do five minutes of exercise instead! Your boredom goes away and you get 5 more activity minutes.
I see absolutely nothing wrong with late night snacking if your hungry. I do it. Your body doesn't know what time it is, and if you are hungry or you haven't gotten enough of a particular needed nutrient, go for it. I work until 10pm so I usually eat a snack before I go to bed around 11. That's fine, but if it's just because you are bored...exercise that boredom away. Put on a song and spazz out to it in the kitchen, if you still want food afterwards, maybe you actually are hungry. :)