Got rid of build warnings (java & cpp)