     printf("Done transfering wordvecs[test_batch].w -> d_w \n");
     d_wordvec.w = d_w;
     
-    cudaError_t err = cudaGetLastError();
+    err = cudaGetLastError();
     if (err != cudaSuccess)
         printf("Error <<< launch >>>: %s\n", cudaGetErrorString(err));
     

    printf("Done transfering wordvecs[test_batch].lens -> d_olens \n");
    d_output.lens = d_olens;
    
    cudaError_t err = cudaGetLastError();
    if (err != cudaSuccess)
        printf("Error <<< launch >>>: %s\n", cudaGetErrorString(err));
    

    printf("Done transfering outputs[test_batch].out -> d_out \n");
    d_output.out = d_out;
    
    err = cudaGetLastError();
    if (err != cudaSuccess)
        printf("Error <<< launch >>>: %s\n", cudaGetErrorString(err));
    
