解决Program received signal SIGSEGV, Segmentation fault.

在写c程序中报错:Program received signal SIGSEGV, Segmentation fault.

最终参照https://blog.csdn.net/quanquanyuanxin/article/details/52883895

发现是我在printf中多写了一个%s。

	// 多写了%s,错误,会报错
//	printf("receive end from [%s : %d] #%s\n", inet_ntoa(client.sin_addr), ntohs(client.sin_port));

猜你喜欢

转载自blog.csdn.net/lllkey/article/details/80415820
今日推荐