Hello,
j'ai une erreur a la compilation d'une extension php, un truc assez incomprehensible
voici l'erreur :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11 /// session_open result declaration. struct session_open_result { net_sessid_t session_id; ///< The session_id choosen by the server, this session_id must be used for all subsequent calls to the server or they will fail. }; /// session_reset result declaration. struct session_reset_result { net_sessid_t session_id; ///< The new session_id choosen by the server. };comme ci j'avais definie session_id dans la meme structure ce qui n'est pas le cas.error C2020: 'session_id' : 'struct' member redefinition
je vous donne mon code entier on sais jamais :
je ne vois vraiment pas le probleme
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99 #ifndef FREEAGE_PHP_MOD_0_INCLUDED #define FREEAGE_PHP_MOD_0_INCLUDED #ifdef __cplusplus extern "C" { #endif #define FREEAGE_PHP_MOD_0_EXTNAME "mod_0" #define FREEAGE_PHP_MOD_0_EXTVER NULL #include "php.h" #ifdef ZTS #include "TSRM.h" #endif #include "net_types.h" PHP_MINIT_FUNCTION(mod_0); PHP_MINFO_FUNCTION(mod_0); PHP_MSHUTDOWN_FUNCTION(mod_0); /* mod_0 functions */ PHP_FUNCTION(session_open); PHP_FUNCTION(session_open_result); PHP_FUNCTION(session_open_result_fetch_array); PHP_FUNCTION(session_reset); PHP_FUNCTION(session_reset_result); PHP_FUNCTION(session_reset_result_fetch_array); PHP_FUNCTION(session_close); PHP_FUNCTION(crypto_set_rsa_key); PHP_FUNCTION(crypto_get_aes_params); PHP_FUNCTION(crypto_get_aes_params_result); PHP_FUNCTION(crypto_get_aes_params_result_fetch_array); PHP_FUNCTION(crypto_begin); PHP_FUNCTION(crypto_begin_result); PHP_FUNCTION(crypto_begin_result_fetch_array); PHP_FUNCTION(crypto_end); ZEND_BEGIN_MODULE_GLOBALS(mod_0) /// session_open result declaration. struct session_open_result { net_sessid_t session_id; ///< The session_id choosen by the server, this session_id must be used for all subsequent calls to the server or they will fail. }; /// session_reset result declaration. struct session_reset_result { net_sessid_t session_id; ///< The new session_id choosen by the server. }; /// crypto_set_rsa_key params declaration. struct crypto_set_rsa_key_params { net_ubyte_t public_key [128]; ///< The client public RSA key. }; /// crypto_get_aes_params result declaration. struct crypto_get_aes_params_result { net_bool_t error; ///< False if ok, or true if an error occurred. net_ubyte_t aes_params [128]; ///< 1024 random bits needed to compute the AES parameters, encrypted with the client public key. }; /// crypto_begin result declaration. struct crypto_begin_result { net_bool_t error; ///< False if ok, or true if an error occurred. }; ZEND_END_MODULE_GLOBALS(mod_0) /* Registration mod_0 inputs. */ extern zend_module_entry mod_0_module_entry; #define phpext_mod_0_ptr &mod_0_module_entry #ifdef ZTS #define MOD_0_G(v) TSRMG(mod_0_globals_id, zend_mod_0_globals *, v) extern int mod_0_globals_id; #else #define MOD_0_G(v) (mod_0_globals.v) extern zend_mod_0_globals mod_0_globals; #endif #ifdef PHP_WIN32 #define MOD_0_API __declspec(dllexport) #else #define MOD_0_API #endif ZEND_EXTERN_MODULE_GLOBALS(mod_0) #ifdef __cplusplus } #endif #endif /* FREEAGE_PHP_MOD_0_INCLUDED */![]()
Partager