what could cause seg fault in this code?

Printable View