Xcode运行模拟器黑屏并意外退出

1 篇文章 0 订阅
1 篇文章 0 订阅

这两天遇到一个很头疼的问题,在Xcode中新建任意项目,只要一run simulator,Xcode马上意外退出,错误报告如下:


Assertion failed: (out_port != 0), function StartDebugserverProcess, file /SourceCache/lldb/lldb-310.2.37/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp, line 720.


上网查了半天,有说把debugger改成none的,有说重置simulator的,有说删除simulator配置信息的,但是都不起作用。最后终于在Apple官网上找到问题的答案:

https://discussions.apple.com/thread/6100778


原来我之前改过hosts文件,把本地的127.0.0.1给删除了。现在把hosts文件恢复到默认状态,这个问题就修复了!!!


附上默认hosts:

## 
# Host Database 

# localhost is used to configure the loopback interface 
# when the system is booting.  Do not change this entry. 
## 
127.0.0.1       localhost 
255.255.255.255 broadcasthost 
::1             localhost  
fe80::1%lo0     localhost

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值