mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-22 21:09:52 +00:00
Warning fixes
This commit is contained in:
parent
640eb1f799
commit
aa94867128
@ -377,6 +377,8 @@ if(NOT MSVC)
|
||||
add_definitions(-Wno-nullability-completeness)
|
||||
add_definitions(-Wno-tautological-pointer-compare)
|
||||
add_definitions(-Wno-deprecated-register)
|
||||
add_definitions(-Wno-sign-conversion)
|
||||
add_definitions(-Wno-shorten-64-to-32)
|
||||
endif()
|
||||
|
||||
if(USE_ASAN)
|
||||
@ -432,11 +434,7 @@ if(NOT MSVC)
|
||||
endif()
|
||||
|
||||
if(IOS)
|
||||
if(IOS_APP_STORE)
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "12.0")
|
||||
else()
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "11.0")
|
||||
endif()
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "12.0")
|
||||
elseif(APPLE AND NOT CMAKE_CROSSCOMPILING)
|
||||
if(LIBRETRO AND ARM64)
|
||||
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.14")
|
||||
|
@ -382,7 +382,7 @@ size_t DirectoryFileHandle::Seek(s32 position, FileMove type)
|
||||
// The actual, underlying file hasn't been truncated (yet.)
|
||||
if (type == FILEMOVE_END) {
|
||||
type = FILEMOVE_BEGIN;
|
||||
position = needsTrunc_ + position;
|
||||
position = (s32)(needsTrunc_ + position);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -135,7 +135,7 @@ void VirtualDiscFileSystem::LoadFileListIndex() {
|
||||
if (trunc != entry.fileName.npos && trunc != entry.fileName.size())
|
||||
entry.fileName.resize(trunc + 1);
|
||||
|
||||
entry.firstBlock = strtol(line.c_str(), NULL, 16);
|
||||
entry.firstBlock = (u32)strtol(line.c_str(), NULL, 16);
|
||||
if (entry.handler != NULL && entry.handler->IsValid()) {
|
||||
HandlerFileHandle temp = entry.handler;
|
||||
if (temp.Open(basePath.ToString(), entry.fileName, FILEACCESS_READ)) {
|
||||
|
@ -1322,7 +1322,7 @@ void sendChat(const std::string &chatString) {
|
||||
strcpy(chat.message, message.c_str());
|
||||
//Send Chat Messages
|
||||
if (IsSocketReady((int)metasocket, false, true) > 0) {
|
||||
int chatResult = send((int)metasocket, (const char*)&chat, sizeof(chat), MSG_NOSIGNAL);
|
||||
int chatResult = (int)send((int)metasocket, (const char*)&chat, sizeof(chat), MSG_NOSIGNAL);
|
||||
NOTICE_LOG(SCENET, "Send Chat %s to Adhoc Server", chat.message);
|
||||
std::string name = g_Config.sNickName;
|
||||
|
||||
@ -1437,7 +1437,7 @@ int friendFinder(){
|
||||
|
||||
// Send Ping to Server, may failed with socket error 10054/10053 if someone else with the same IP already connected to AdHoc Server (the server might need to be modified to differentiate MAC instead of IP)
|
||||
if (IsSocketReady((int)metasocket, false, true) > 0) {
|
||||
int iResult = send((int)metasocket, (const char*)&opcode, 1, MSG_NOSIGNAL);
|
||||
int iResult = (int)send((int)metasocket, (const char*)&opcode, 1, MSG_NOSIGNAL);
|
||||
int error = errno;
|
||||
// KHBBS seems to be getting error 10053 often
|
||||
if (iResult == SOCKET_ERROR) {
|
||||
@ -1464,7 +1464,7 @@ int friendFinder(){
|
||||
|
||||
// Check for Incoming Data
|
||||
if (IsSocketReady((int)metasocket, true, false) > 0) {
|
||||
int received = recv((int)metasocket, (char*)(rx + rxpos), sizeof(rx) - rxpos, MSG_NOSIGNAL);
|
||||
int received = (int)recv((int)metasocket, (char*)(rx + rxpos), sizeof(rx) - rxpos, MSG_NOSIGNAL);
|
||||
|
||||
// Free Network Lock
|
||||
//_freeNetworkLock();
|
||||
@ -2262,7 +2262,7 @@ int initNetwork(SceNetAdhocctlAdhocId *adhoc_id){
|
||||
|
||||
IsSocketReady((int)metasocket, false, true, nullptr, adhocDefaultTimeout);
|
||||
DEBUG_LOG(SCENET, "InitNetwork: Sending LOGIN OPCODE %d", packet.base.opcode);
|
||||
int sent = send((int)metasocket, (char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
int sent = (int)send((int)metasocket, (char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (sent > 0) {
|
||||
socklen_t addrLen = sizeof(LocalIP);
|
||||
memset(&LocalIP, 0, addrLen);
|
||||
|
@ -859,7 +859,7 @@ void connect_user(SceNetAdhocctlUserNode * user, SceNetAdhocctlGroupName * group
|
||||
packet.ip = user->resolver.ip;
|
||||
|
||||
// Send Data
|
||||
int iResult = send(peer->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
int iResult = (int)send(peer->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: connect_user[send peer] (Socket error %d)", errno);
|
||||
|
||||
// Set Player Name
|
||||
@ -872,7 +872,7 @@ void connect_user(SceNetAdhocctlUserNode * user, SceNetAdhocctlGroupName * group
|
||||
packet.ip = peer->resolver.ip;
|
||||
|
||||
// Send Data
|
||||
iResult = send(user->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
iResult = (int)send(user->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: connect_user[send user] (Socket error %d)", errno);
|
||||
|
||||
// Set BSSID
|
||||
@ -894,7 +894,7 @@ void connect_user(SceNetAdhocctlUserNode * user, SceNetAdhocctlGroupName * group
|
||||
g->playercount++;
|
||||
|
||||
// Send Network BSSID to User
|
||||
int iResult = send(user->stream, (const char*)&bssid, sizeof(bssid), MSG_NOSIGNAL);
|
||||
int iResult = (int)send(user->stream, (const char*)&bssid, sizeof(bssid), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: connect_user[send user bssid] (Socket error %d)", errno);
|
||||
|
||||
// Notify User
|
||||
@ -986,7 +986,7 @@ void disconnect_user(SceNetAdhocctlUserNode * user)
|
||||
packet.ip = user->resolver.ip;
|
||||
|
||||
// Send Data
|
||||
int iResult = send(peer->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
int iResult = (int)send(peer->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: disconnect_user[send peer] (Socket error %d)", errno);
|
||||
|
||||
// Move Pointer
|
||||
@ -1085,13 +1085,13 @@ void send_scan_results(SceNetAdhocctlUserNode * user)
|
||||
}
|
||||
|
||||
// Send Group Packet
|
||||
int iResult = send(user->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
int iResult = (int)send(user->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: send_scan_result[send user] (Socket error %d)", errno);
|
||||
}
|
||||
|
||||
// Notify Player of End of Scan
|
||||
uint8_t opcode = OPCODE_SCAN_COMPLETE;
|
||||
int iResult = send(user->stream, (const char*)&opcode, 1, MSG_NOSIGNAL);
|
||||
int iResult = (int)send(user->stream, (const char*)&opcode, 1, MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: send_scan_result[send peer complete] (Socket error %d)", errno);
|
||||
|
||||
// Notify User
|
||||
@ -1150,7 +1150,7 @@ void spread_message(SceNetAdhocctlUserNode *user, const char *message)
|
||||
strcpy(packet.base.message, message);
|
||||
|
||||
// Send Data
|
||||
int iResult = send(user->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
int iResult = (int)send(user->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: spread_message[send user chat] (Socket error %d)", errno);
|
||||
}
|
||||
}
|
||||
@ -1192,7 +1192,7 @@ void spread_message(SceNetAdhocctlUserNode *user, const char *message)
|
||||
packet.name = user->resolver.name;
|
||||
|
||||
// Send Data
|
||||
int iResult = send(peer->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
int iResult = (int)send(peer->stream, (const char*)&packet, sizeof(packet), MSG_NOSIGNAL);
|
||||
if (iResult < 0) ERROR_LOG(SCENET, "AdhocServer: spread_message[send peer chat] (Socket error %d)", errno);
|
||||
|
||||
// Move Pointer
|
||||
@ -1939,7 +1939,7 @@ int server_loop(int server)
|
||||
SceNetAdhocctlUserNode * next = user->next;
|
||||
|
||||
// Receive Data from User
|
||||
int recvresult = recv(user->stream, (char*)user->rx + user->rxpos, sizeof(user->rx) - user->rxpos, MSG_NOSIGNAL);
|
||||
int recvresult = (int)recv(user->stream, (char*)user->rx + user->rxpos, sizeof(user->rx) - user->rxpos, MSG_NOSIGNAL);
|
||||
|
||||
// Connection Closed or Timed Out
|
||||
if(recvresult == 0 || (recvresult == -1 && errno != EAGAIN && errno != EWOULDBLOCK) || get_user_state(user) == USER_STATE_TIMED_OUT)
|
||||
|
@ -12,7 +12,7 @@
|
||||
# PPSSPP platform flags
|
||||
set(MOBILE_DEVICE ON)
|
||||
set(USING_GLES2 ON)
|
||||
set(IPHONEOS_DEPLOYMENT_TARGET 11.0)
|
||||
set(IPHONEOS_DEPLOYMENT_TARGET 12.0)
|
||||
add_definitions(
|
||||
-DGL_ETC1_RGB8_OES=0
|
||||
-U__STRICT_ANSI__
|
||||
|
@ -32,6 +32,8 @@
|
||||
<true/>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<false/>
|
||||
<key>UIRequiresFullScreen</key>
|
||||
<true/>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>arm64</string>
|
||||
@ -59,11 +61,6 @@
|
||||
<string>Default.png</string>
|
||||
<key>UIFileSharingEnabled</key>
|
||||
<true/>
|
||||
<key>UIDeviceFamily</key>
|
||||
<array>
|
||||
<integer>1</integer>
|
||||
<integer>2</integer>
|
||||
</array>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>Launch Screen</string>
|
||||
<key>CFBundleDocumentTypes</key>
|
||||
|
@ -32,6 +32,8 @@
|
||||
<true/>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<false/>
|
||||
<key>UIRequiresFullScreen</key>
|
||||
<true/>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>arm64</string>
|
||||
|
@ -18,3 +18,5 @@ else
|
||||
plutil -replace CFBundleShortVersionString -string "" ${PPSSPP}/Info.plist
|
||||
plutil -replace CFBundleVersion -string "" ${PPSSPP}/Info.plist
|
||||
fi
|
||||
|
||||
echo "macbundle.sh: Updated ${PPSSPP}/Info.plist"
|
Loading…
Reference in New Issue
Block a user