Your test program is guaranteed to fail. You do strlen() on a nonexistant string (I think you wanted argv[1], which would give you the "a").
It is extremely unlikely that the problem is actually in strlen(): strlen() only uncovered the problem. -- @edgy - segmentation fault strlen - implicated apt-get, aptitude, synaptic, adept https://launchpad.net/bugs/57140 -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs