AVALANCHE: Fix various warnings reported by GCC and/or wjp