remove unused variables to compile in higher gcc version