more strncpy -> ast_copy_string conversions, fixing some buglets along the way