Fixes for different hooks in the lib
	modified:   portability.c
	modified:   portability.h