kubernetes-client / c

Official C client library for Kubernetes
Apache License 2.0
141 stars 45 forks source link

issue in postData to support 32bit #199

Closed hai22yu23 closed 11 months ago

hai22yu23 commented 11 months ago

postData in apiClient.c has issues for supporting 32bit:

/* it should add type cast (curl_off_t)

curl_easy_setopt(handle, CURLOPT_POSTFIELDSIZE_LARGE, (curl_off_t) strlen (bodyParameters));

brendandburns commented 11 months ago

This needs to be fixed in the upstream OpenAPI generator:

https://github.com/OpenAPITools/openapi-generator/blob/master/modules/openapi-generator/src/main/resources/C-libcurl/apiClient.c.mustache#L238

Here is an example PR that you can use as a model: https://github.com/OpenAPITools/openapi-generator/pull/14332

Once that is fixed in the generator, we can regenerate the client.

ityuhui commented 11 months ago

The upstream PR https://github.com/OpenAPITools/openapi-generator/pull/16238 is merged. I'd like to regenerate the client now.

Reference: https://github.com/kubernetes-client/c/blob/master/docs/how-to-regenerate-the-c-client.md#regenerate-with-openapi-generator

The project also has a GitHub Action that automatically generates the client library: https://github.com/kubernetes-client/c/actions/workflows/generate.yml that requires maintainer permission to trigger.