Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'system' is unavailable: not available on iOS #87

Open
daasan123 opened this issue Mar 3, 2018 · 4 comments
Open

'system' is unavailable: not available on iOS #87

daasan123 opened this issue Mar 3, 2018 · 4 comments

Comments

@daasan123
Copy link

Demo 运行出错:'system' is unavailable: not available on iOS

@xiaoliuTX
Copy link

怎么官网没有反馈啊

@keirlee
Copy link

keirlee commented Apr 25, 2018

system方法在ios11被废弃了,看这里https://blog.csdn.net/wangwenfei1990/article/details/78122134

@shengdoushi
Copy link

shengdoushi commented Jul 17, 2018

Apple已经废弃这个API了,可以使用其他API代替,或是直接禁用 os.execute 的实现吧 。
看楼上的解决方案是用 nftw() 了, 这有点不对头吧,因为是 os.execute 内部调用了 system() API.

nftw() 和 system() 不是一个功能吧,这还不如用 popen() 正确点。

@shengdoushi
Copy link

"Use posix_spawn APIs or NSTask instead."
苹果的推荐替代方案是 posix_spawn, 也可以试试这个

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants