Fix build and add warning