In SSH-1 there's a function that takes a void * that it casts to the state of the login layer. The corresponding function in SSH-2 casts it to the state of a differently named layer, but I had still called the parameter 'loginv'.