@@ -81,30 +81,20 @@ static int mdns_test_service_txt_set(const char *service, const char *proto, ui
81
81
static int mdns_test_sub_service_add (const char * sub_name , const char * service_name , const char * proto , uint32_t port )
82
82
{
83
83
if (mdns_service_add (NULL , service_name , proto , port , NULL , 0 )) {
84
- // This is expected failure as the service thread is not running
84
+ return ESP_FAIL ;
85
85
}
86
- mdns_action_t * a = NULL ;
87
- GetLastItem (& a );
88
- mdns_test_execute_action (a );
89
86
90
87
if (_mdns_get_service_item (service_name , proto , NULL ) == NULL ) {
91
88
return ESP_FAIL ;
92
89
}
93
- int ret = mdns_service_subtype_add_for_host (NULL , service_name , proto , NULL , sub_name );
94
- a = NULL ;
95
- GetLastItem (& a );
96
- mdns_test_execute_action (a );
97
- return ret ;
90
+ return mdns_service_subtype_add_for_host (NULL , service_name , proto , NULL , sub_name );
98
91
}
99
92
100
93
static int mdns_test_service_add (const char * service_name , const char * proto , uint32_t port )
101
94
{
102
95
if (mdns_service_add (NULL , service_name , proto , port , NULL , 0 )) {
103
- // This is expected failure as the service thread is not running
96
+ return ESP_FAIL ;
104
97
}
105
- mdns_action_t * a = NULL ;
106
- GetLastItem (& a );
107
- mdns_test_execute_action (a );
108
98
109
99
if (_mdns_get_service_item (service_name , proto , NULL ) == NULL ) {
110
100
return ESP_FAIL ;
@@ -270,9 +260,6 @@ int main(int argc, char **argv)
270
260
}
271
261
#ifndef MDNS_NO_SERVICES
272
262
mdns_service_remove_all ();
273
- mdns_action_t * a = NULL ;
274
- GetLastItem (& a );
275
- mdns_test_execute_action (a );
276
263
#endif
277
264
ForceTaskDelete ();
278
265
mdns_free ();
0 commit comments