Rev 4351 | Rev 4582 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 4351 | Rev 4505 | ||
---|---|---|---|
Line 125... | Line 125... | ||
125 | * @param configuration The found configured values. Output parameter. |
125 | * @param configuration The found configured values. Output parameter. |
126 | * @param count The desired settings count. Input parameter. |
126 | * @param count The desired settings count. Input parameter. |
127 | * @param data The found configuration settings data. Output parameter. |
127 | * @param data The found configuration settings data. Output parameter. |
128 | * @returns EOK. |
128 | * @returns EOK. |
129 | */ |
129 | */ |
130 | int net_get_conf( measured_strings_ref netif_conf, measured_string_ref configuration, int count, char ** data ); |
130 | int net_get_conf( measured_strings_ref netif_conf, measured_string_ref configuration, size_t count, char ** data ); |
131 | 131 | ||
132 | /** Networking module global data. |
132 | /** Networking module global data. |
133 | */ |
133 | */ |
134 | net_globals_t net_globals; |
134 | net_globals_t net_globals; |
135 | 135 | ||
Line 158... | Line 158... | ||
158 | 158 | ||
159 | pm_destroy(); |
159 | pm_destroy(); |
160 | return EOK; |
160 | return EOK; |
161 | } |
161 | } |
162 | 162 | ||
163 | int net_get_device_conf_req( int net_phone, device_id_t device_id, measured_string_ref * configuration, int count, char ** data ){ |
163 | int net_get_device_conf_req( int net_phone, device_id_t device_id, measured_string_ref * configuration, size_t count, char ** data ){ |
164 | netif_ref netif; |
164 | netif_ref netif; |
165 | 165 | ||
166 | if( !( configuration && ( count > 0 ))) return EINVAL; |
166 | if( !( configuration && ( count > 0 ))) return EINVAL; |
167 | netif = netifs_find( & net_globals.netifs, device_id ); |
167 | netif = netifs_find( & net_globals.netifs, device_id ); |
168 | if( netif ){ |
168 | if( netif ){ |
Line 170... | Line 170... | ||
170 | }else{ |
170 | }else{ |
171 | return net_get_conf( NULL, * configuration, count, data ); |
171 | return net_get_conf( NULL, * configuration, count, data ); |
172 | } |
172 | } |
173 | } |
173 | } |
174 | 174 | ||
175 | int net_get_conf_req( int net_phone, measured_string_ref * configuration, int count, char ** data ){ |
175 | int net_get_conf_req( int net_phone, measured_string_ref * configuration, size_t count, char ** data ){ |
176 | if( !( configuration && ( count > 0 ))) return EINVAL; |
176 | if( !( configuration && ( count > 0 ))) return EINVAL; |
177 | return net_get_conf( NULL, * configuration, count, data ); |
177 | return net_get_conf( NULL, * configuration, count, data ); |
178 | } |
178 | } |
179 | 179 | ||
180 | int net_get_conf( measured_strings_ref netif_conf, measured_string_ref configuration, int count, char ** data ){ |
180 | int net_get_conf( measured_strings_ref netif_conf, measured_string_ref configuration, size_t count, char ** data ){ |
181 | measured_string_ref setting; |
181 | measured_string_ref setting; |
182 | int index; |
182 | size_t index; |
183 | 183 | ||
184 | if( data ) * data = NULL; |
184 | if( data ) * data = NULL; |
185 | for( index = 0; index < count; ++ index ){ |
185 | for( index = 0; index < count; ++ index ){ |
186 | setting = measured_strings_find( netif_conf, configuration[ index ].value, 0 ); |
186 | setting = measured_strings_find( netif_conf, configuration[ index ].value, 0 ); |
187 | if( ! setting ){ |
187 | if( ! setting ){ |