now it is compiling, but it seems that i generated a memory leak :-)