File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -288,7 +288,7 @@ static void proc_open_rsrc_dtor(zend_resource *rsrc)
288
288
289
289
_php_free_envp (proc -> env );
290
290
efree (proc -> pipes );
291
- zend_string_release_ex (proc -> command , false );
291
+ efree (proc -> command );
292
292
efree (proc );
293
293
}
294
294
/* }}} */
@@ -374,7 +374,7 @@ PHP_FUNCTION(proc_get_status)
374
374
}
375
375
376
376
array_init (return_value );
377
- add_assoc_str (return_value , "command" , proc -> command );
377
+ add_assoc_string (return_value , "command" , proc -> command );
378
378
add_assoc_long (return_value , "pid" , (zend_long )proc -> child );
379
379
380
380
#ifdef PHP_WIN32
@@ -1237,7 +1237,7 @@ PHP_FUNCTION(proc_open)
1237
1237
}
1238
1238
1239
1239
proc = (php_process_handle * ) emalloc (sizeof (php_process_handle ));
1240
- proc -> command = zend_string_copy ( command_str );
1240
+ proc -> command = estrdup ( ZSTR_VAL ( command_str ) );
1241
1241
proc -> pipes = emalloc (sizeof (zend_resource * ) * ndesc );
1242
1242
proc -> npipes = ndesc ;
1243
1243
proc -> child = child ;
Original file line number Diff line number Diff line change @@ -41,6 +41,6 @@ typedef struct _php_process_handle {
41
41
#endif
42
42
size_t npipes ;
43
43
zend_resource * * pipes ;
44
- zend_string * command ;
44
+ char * command ;
45
45
php_process_env env ;
46
46
} php_process_handle ;
You can’t perform that action at this time.
0 commit comments