Skip to content

Commit 83799e2

Browse files
committed
Update examples after the data types of function prameters changes from "int" to "int*"
1 parent 82eedf0 commit 83799e2

File tree

11 files changed

+90
-87
lines changed

11 files changed

+90
-87
lines changed

examples/auth_provider/main.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ void list_pod(apiClient_t * apiClient)
1010
v1_pod_list_t *pod_list = NULL;
1111
pod_list = CoreV1API_listNamespacedPod(apiClient, "default", /*namespace */
1212
NULL, /* pretty */
13-
0, /* allowWatchBookmarks */
13+
NULL, /* allowWatchBookmarks */
1414
NULL, /* continue */
1515
NULL, /* fieldSelector */
1616
NULL, /* labelSelector */
17-
0, /* limit */
17+
NULL, /* limit */
1818
NULL, /* resourceVersion */
1919
NULL, /* resourceVersionMatch */
20-
0, /* sendInitialEvents */
21-
0, /* timeoutSeconds */
22-
0 /* watch */
20+
NULL, /* sendInitialEvents */
21+
NULL, /* timeoutSeconds */
22+
NULL /* watch */
2323
);
2424
printf("The return code of HTTP request=%ld\n", apiClient->response_code);
2525
if (pod_list) {

examples/configmap/main.c

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#include <unistd.h>
88

99
void create_configmap(apiClient_t * apiClient, char *name, char *namespace_)
10-
{
10+
{
1111
char *api_version = strdup("v1");
1212
char *kind = strdup("ConfigMap");
1313

@@ -41,12 +41,12 @@ void create_configmap(apiClient_t * apiClient, char *name, char *namespace_)
4141
meta);
4242

4343
v1_config_map_t *ret_config_map = CoreV1API_createNamespacedConfigMap(apiClient,
44-
namespace_,
45-
body,
46-
NULL,
47-
NULL,
48-
NULL,
49-
NULL);
44+
namespace_,
45+
body,
46+
NULL,
47+
NULL,
48+
NULL,
49+
NULL);
5050

5151
printf("%s: The return code of HTTP request=%ld\n", __func__, apiClient->response_code);
5252

@@ -70,18 +70,18 @@ void create_configmap(apiClient_t * apiClient, char *name, char *namespace_)
7070
void list_configmap(apiClient_t * apiClient, char *namespace_)
7171
{
7272
v1_config_map_list_t *config_map_list = CoreV1API_listNamespacedConfigMap(apiClient,
73-
namespace_, // char *namespace
73+
namespace_, // char *namespace
7474
"true", // char *pretty
75-
0, // int allowWatchBookmarks
76-
NULL, // char * _continue
77-
NULL, // char * fieldSelector
78-
NULL, // char * labelSelector
79-
0, // int limit
80-
NULL, // char * resourceVersion
81-
NULL, // char * resourceVersionMatch
82-
0, // sendInitialEvents
83-
0, // int timeoutSeconds
84-
0 //int watch
75+
NULL, // int *allowWatchBookmarks
76+
NULL, // char *_continue
77+
NULL, // char *fieldSelector
78+
NULL, // char *labelSelector
79+
NULL, // int *limit
80+
NULL, // char *resourceVersion
81+
NULL, // char *resourceVersionMatch
82+
NULL, // sendInitialEvents
83+
NULL, // int *timeoutSeconds
84+
NULL //int *watch
8585
);
8686

8787
printf("%s: The return code of HTTP request=%ld\n", __func__, apiClient->response_code);
@@ -117,14 +117,14 @@ void list_configmap(apiClient_t * apiClient, char *namespace_)
117117
void delete_configmap(apiClient_t * apiClient, char *name, char *namespace_)
118118
{
119119
v1_status_t *status = CoreV1API_deleteNamespacedConfigMap(apiClient,
120-
name, // char *name
121-
namespace_, // char *namespace
122-
NULL, // char *pretty
123-
NULL, // char *dryRun
124-
0, // int gracePeriodSeconds
125-
0, // int orphanDependents
126-
NULL, // char *propagationPolicy
127-
NULL // v1_delete_options_t *body
120+
name, // char *name
121+
namespace_, // char *namespace
122+
NULL, // char *pretty
123+
NULL, // char *dryRun
124+
NULL, // int *gracePeriodSeconds
125+
NULL, // int *orphanDependents
126+
NULL, // char *propagationPolicy
127+
NULL // v1_delete_options_t *body
128128
);
129129

130130
printf("The return code of HTTP request=%ld\n", apiClient->response_code);

examples/delete_pod/main.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88
void delete_a_pod(apiClient_t * apiClient)
99
{
1010
v1_pod_t *pod = CoreV1API_deleteNamespacedPod(apiClient,
11-
"test-pod-6", // char *name
12-
"default", // char *namespace
13-
NULL, // char *pretty
14-
NULL, // char *dryRun
15-
30, // int gracePeriodSeconds
16-
0, // int orphanDependents
17-
NULL, // char *propagationPolicy
18-
NULL // v1_delete_options_t *body
11+
"test-pod-6", // char *name
12+
"default", // char *namespace
13+
NULL, // char *pretty
14+
NULL, // char *dryRun
15+
NULL, // int *gracePeriodSeconds
16+
NULL, // int *orphanDependents
17+
NULL, // char *propagationPolicy
18+
NULL // v1_delete_options_t *body
1919
);
2020

2121
printf("The return code of HTTP request=%ld\n", apiClient->response_code);

examples/exec_provider/list_pod_by_exec_provider.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ void list_pod(apiClient_t * apiClient)
1010
v1_pod_list_t *pod_list = NULL;
1111
pod_list = CoreV1API_listNamespacedPod(apiClient, "default", /*namespace */
1212
NULL, /* pretty */
13-
0, /* allowWatchBookmarks */
13+
NULL, /* allowWatchBookmarks */
1414
NULL, /* continue */
1515
NULL, /* fieldSelector */
1616
NULL, /* labelSelector */
17-
0, /* limit */
17+
NULL, /* limit */
1818
NULL, /* resourceVersion */
1919
NULL, /* resourceVersionMatch */
20-
0, /* sendInitialEvents */
21-
0, /* timeoutSeconds */
22-
0 /* watch */
20+
NULL, /* sendInitialEvents */
21+
NULL, /* timeoutSeconds */
22+
NULL /* watch */
2323
);
2424
printf("The return code of HTTP request=%ld\n", apiClient->response_code);
2525
if (pod_list) {

examples/list_event/main.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ void list_event(apiClient_t * apiClient)
1010
{
1111
core_v1_event_list_t *event_list = CoreV1API_listNamespacedEvent(apiClient, "default", /*namespace */
1212
"true", /* pretty */
13-
0, /* allowWatchBookmarks */
13+
NULL, /* allowWatchBookmarks */
1414
NULL, /* continue */
1515
NULL, /* fieldSelector */
1616
NULL, /* labelSelector */
17-
0, /* limit */
17+
NULL, /* limit */
1818
NULL, /* resourceVersion */
1919
NULL, /* resourceVersionMatch */
20-
0, /* sendInitialEvents */
21-
0, /* timeoutSeconds */
22-
0 /* watch */
20+
NULL, /* sendInitialEvents */
21+
NULL, /* timeoutSeconds */
22+
NULL /* watch */
2323
);
2424
printf("The return code of HTTP request=%ld\n", apiClient->response_code);
2525
if (event_list) {

examples/list_pod/main.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@ void list_pod(apiClient_t * apiClient)
77
v1_pod_list_t *pod_list = NULL;
88
pod_list = CoreV1API_listNamespacedPod(apiClient, "default", /*namespace */
99
NULL, /* pretty */
10-
0, /* allowWatchBookmarks */
10+
NULL, /* allowWatchBookmarks */
1111
NULL, /* continue */
1212
NULL, /* fieldSelector */
1313
NULL, /* labelSelector */
14-
0, /* limit */
14+
NULL, /* limit */
1515
NULL, /* resourceVersion */
1616
NULL, /* resourceVersionMatch */
17-
0, /* sendInitialEvents */
18-
0, /* timeoutSeconds */
19-
0 /* watch */
17+
NULL, /* sendInitialEvents */
18+
NULL, /* timeoutSeconds */
19+
NULL /* watch */
2020
);
2121
printf("The return code of HTTP request=%ld\n", apiClient->response_code);
2222
if (pod_list) {

examples/list_pod_incluster/main.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,16 @@ void list_pod(apiClient_t * apiClient)
1111
v1_pod_list_t *pod_list = NULL;
1212
pod_list = CoreV1API_listNamespacedPod(apiClient, "default", /*namespace */
1313
NULL, /* pretty */
14-
0, /* allowWatchBookmarks */
14+
NULL, /* allowWatchBookmarks */
1515
NULL, /* continue */
1616
NULL, /* fieldSelector */
1717
NULL, /* labelSelector */
18-
0, /* limit */
18+
NULL, /* limit */
1919
NULL, /* resourceVersion */
2020
NULL, /* resourceVersionMatch */
21-
0, /* sendInitialEvents */
22-
0, /* timeoutSeconds */
23-
0 /* watch */
21+
NULL, /* sendInitialEvents */
22+
NULL, /* timeoutSeconds */
23+
NULL /* watch */
2424
);
2525
printf("The return code of HTTP request=%ld\n", apiClient->response_code);
2626
if (pod_list) {

examples/list_pod_with_invalid_kubeconfig/main.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@ void list_pod(apiClient_t * apiClient)
77
v1_pod_list_t *pod_list = NULL;
88
pod_list = CoreV1API_listNamespacedPod(apiClient, "default", /*namespace */
99
NULL, /* pretty */
10-
0, /* allowWatchBookmarks */
10+
NULL, /* allowWatchBookmarks */
1111
NULL, /* continue */
1212
NULL, /* fieldSelector */
1313
NULL, /* labelSelector */
14-
0, /* limit */
14+
NULL, /* limit */
1515
NULL, /* resourceVersion */
1616
NULL, /* resourceVersionMatch */
17-
0, /* sendInitialEvents */
18-
0, /* timeoutSeconds */
19-
0 /* watch */
17+
NULL, /* sendInitialEvents */
18+
NULL, /* timeoutSeconds */
19+
NULL /* watch */
2020
);
2121
printf("The return code of HTTP request=%ld\n", apiClient->response_code);
2222
if (pod_list) {

examples/list_secret/main.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ void list_secret(apiClient_t * apiClient)
1010
v1_secret_list_t *secret_list = CoreV1API_listNamespacedSecret(apiClient,
1111
"default", // char *namespace
1212
"true", // char *pretty
13-
0, // int allowWatchBookmarks
14-
NULL, // char * _continue
15-
NULL, // char * fieldSelector
16-
NULL, // char * labelSelector
17-
0, // int limit
18-
NULL, // char * resourceVersion
19-
NULL, // char * resourceVersionMatch
20-
0, // sendInitialEvents
21-
0, // int timeoutSeconds
22-
0 // int watch
13+
NULL, // int *allowWatchBookmarks
14+
NULL, // char *_continue
15+
NULL, // char *fieldSelector
16+
NULL, // char *labelSelector
17+
NULL, // int *limit
18+
NULL, // char *resourceVersion
19+
NULL, // char *resourceVersionMatch
20+
NULL, // int *sendInitialEvents
21+
NULL, // int *timeoutSeconds
22+
NULL // int *watch
2323
);
2424

2525
printf("The return code of HTTP request=%ld\n", apiClient->response_code);

0 commit comments

Comments
 (0)