Small error in matrixmul_drv/matrixmul_drv.cpp? Just an error report

Hi,

I just tried to compile the CUDA SDK samples and

[font=“Courier”]matrixmul_drv/matrixmul_drv.cpp[/font]

refused to compile. The error message was (using gcc version 4.1.2):

[font=“Courier”]matrixmul_drv.cpp: In function ‘CUresult initCUDA(char*, CUfunc_st**)’:
matrixmul_drv.cpp:207: error: jump to label ‘Error’
matrixmul_drv.cpp:191: error: from here
matrixmul_drv.cpp:193: error: crosses initialization of ‘char* module_path’
matrixmul_drv.cpp:207: error: jump to label ‘Error’
matrixmul_drv.cpp:187: error: from here
matrixmul_drv.cpp:193: error: crosses initialization of ‘char* module_path’
matrixmul_drv.cpp:207: error: jump to label ‘Error’
matrixmul_drv.cpp:184: error: from here
matrixmul_drv.cpp:193: error: crosses initialization of ‘char* module_path’[/font]

I took a look at the function and there seems to be a small error (I never used goto’s so I am not sure if this really is an error). I think [font=“Courier”]char* module_path[/font] should be defined before the first goto or the code after the error label can not be compiled/executed since it uses [font=“Courier”]module_path[/font]. :)

-Jens

BTW: Except that problem everything is working as expected even on an unsupported Ubuntu system. :)