Some compiling problems have appeared in some OpenCV versions due to cvDestroyWindow function, and it's not really necessary