- disallow non compressed tileset downloads when client IP not on same subnet as host

- bugfix for LAN server broadcasting
- bugfix for empty message on player disconnect (now properly shows that player switched to AI mode)
This commit is contained in:
Mark Vejvoda
2011-11-29 05:07:18 +00:00
parent 28ae161c25
commit 7cf9c189b2
13 changed files with 153 additions and 34 deletions

View File

@@ -139,6 +139,8 @@ extern void ftpCloseTransmission(int id);
extern int ftpGetActiveTransCnt(void);
extern int ftpFindAccount(const char* name);
extern const char * ftpFindAccountById(int userid);
extern int ftpCheckPassword(int userId, const char* passw);
extern int ftpCheckAccRights(int userId, int accRights);
extern const char* ftpGetRoot(int userId, int* len);

View File

@@ -38,7 +38,9 @@
extern "C" {
#endif
void ftpInit(ftpFindExternalFTPServerIpType cb1, ftpAddUPNPPortForwardType cb2, ftpRemoveUPNPPortForwardType cb3, ftpIsValidClientType cb4);
void ftpInit(ftpFindExternalFTPServerIpType cb1, ftpAddUPNPPortForwardType cb2,
ftpRemoveUPNPPortForwardType cb3, ftpIsValidClientType cb4,
ftpIsClientAllowedToGetFileType cb5);
int ftpCreateAccount(const char* name, const char* passw, const char* root, int accRights);
int ftpDeleteAccount(const char* name);
int ftpStart(int portNumber);

View File

@@ -70,11 +70,13 @@ typedef ip_t (*ftpFindExternalFTPServerIpType)(ip_t clientIp);
typedef void (*ftpAddUPNPPortForwardType)(int internalPort, int externalPort);
typedef void (*ftpRemoveUPNPPortForwardType)(int internalPort, int externalPort);
typedef int (*ftpIsValidClientType)(ip_t clientIp);
typedef int (*ftpIsClientAllowedToGetFileType)(ip_t clientIp, const char *username, const char *filename);
ftpFindExternalFTPServerIpType ftpFindExternalFTPServerIp;
ftpAddUPNPPortForwardType ftpAddUPNPPortForward;
ftpRemoveUPNPPortForwardType ftpRemoveUPNPPortForward;
ftpIsValidClientType ftpIsValidClient;
ftpIsClientAllowedToGetFileType ftpIsClientAllowedToGetFile;
#ifdef __cplusplus
}