wrong struct being accessed