update to the changes in the api
some cleanings to avoid warnings if using stricter compiler's flags