Closed 903d09f6-e821-4655-9e8b-7e6068b26f74 closed 4 months ago
Welcome @903d09f6-e821-4655-9e8b-7e6068b26f74!
It looks like this is your first PR to kubernetes-client/c 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.
You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.
You can also check if kubernetes-client/c has its own contribution guidelines.
You may want to refer to our testing guide if you run into trouble with your tests not passing.
If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!
Thank you, and welcome to Kubernetes. :smiley:
To avoid duplication, I recommend moving all 3 blocks below
#ifndef _WIN32
pclose(fp);
#else
_pclose(fp);
#endif
to the last of function:
end:
if (result_string) {
free(result_string);
result_string = NULL; // <-- This time I added a new line
}
if (fp) {
#ifndef _WIN32
pclose(fp);
#else
_pclose(fp);
#endif
fp = NULL; // <-- This time I added a new line
}
return rc;
to
rc = -1;
goto end;
I agree to your suggestion. HERE is the revision. Thank you.
I'm OK with this PR. Please wait a moment to see if @brendandburns has a comment.
/lgtm /approve
thanks for the PR!
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: 903d09f6-e821-4655-9e8b-7e6068b26f74, brendandburns
The full list of commands accepted by this bot can be found here.
The pull request process is described here
This fix is for issue #243
pclose
toconfig/exec_provider.c
beforekube_exec_and_get_result
is returned by the exception handling.fclose
toconfig/kube_config_yaml.c
beforekubeyaml_save_kubeconfig
is returned by the exception handling.