We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
您好,在执行react-native run-ios后,提示BUILD FAILED,具体信息如下: ./ReactNative/GitHubPopular/node_modules/react-native/Libraries/WebSocket/RCTSRWebSocket.m:494:3: error: ignoring return value of function declared with warn_unused_result attribute [-Werror,-Wunused-result] SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes); ^~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./ReactNative/GitHubPopular/node_modules/react-native/Libraries/WebSocket/RCTSRWebSocket.m:1334:5: error: ignoring return value of function declared with warn_unused_result attribute [-Werror,-Wunused-result] SecRandomCopyBytes(kSecRandomDefault, sizeof(uint32_t), (uint8_t *)mask_key); ^~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 2 errors generated._ 求指教~
./ReactNative/GitHubPopular/node_modules/react-native/Libraries/WebSocket/RCTSRWebSocket.m:494:3: error: ignoring return value of function declared with warn_unused_result attribute [-Werror,-Wunused-result] SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes); ^~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./ReactNative/GitHubPopular/node_modules/react-native/Libraries/WebSocket/RCTSRWebSocket.m:1334:5: error: ignoring return value of function declared with warn_unused_result attribute [-Werror,-Wunused-result] SecRandomCopyBytes(kSecRandomDefault, sizeof(uint32_t), (uint8_t *)mask_key); ^~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 2 errors generated._
The text was updated successfully, but these errors were encountered:
fix in #1
Sorry, something went wrong.
在中文官网找到了答案: 将 SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes); 改为 (void)SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes);即可。
SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes);
(void)SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes);
No branches or pull requests
您好,在执行react-native run-ios后,提示BUILD FAILED,具体信息如下:
./ReactNative/GitHubPopular/node_modules/react-native/Libraries/WebSocket/RCTSRWebSocket.m:494:3: error: ignoring return value of function declared with warn_unused_result attribute [-Werror,-Wunused-result] SecRandomCopyBytes(kSecRandomDefault, keyBytes.length, keyBytes.mutableBytes); ^~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./ReactNative/GitHubPopular/node_modules/react-native/Libraries/WebSocket/RCTSRWebSocket.m:1334:5: error: ignoring return value of function declared with warn_unused_result attribute [-Werror,-Wunused-result] SecRandomCopyBytes(kSecRandomDefault, sizeof(uint32_t), (uint8_t *)mask_key); ^~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 2 errors generated._
求指教~
The text was updated successfully, but these errors were encountered: