kubernetes-client / c

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

Multiple incompatible types warning at compilation #123

Closed petitlapin closed 2 years ago

petitlapin commented 2 years ago

Hi, not sure how important it is but in case, when compiling with icc 2021 or gcc 8.5:

c-0.3.0/kubernetes/model/v1_json_schema_props.c(844): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      additional_items_local_object = object_parseFromJSON(additional_items); //object
                                                           ^
c-0.3.0/kubernetes/model/v1_json_schema_props.c(851): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      additional_properties_local_object = object_parseFromJSON(additional_properties); //object
                                                                ^
c-0.3.0/kubernetes/model/v1_json_schema_props.c(900): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      _default_local_object = object_parseFromJSON(_default); //object
                                                   ^
c-0.3.0/kubernetes/model/v1_json_schema_props.c(951): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
          object_t *_enumItem = object_parseFromJSON(_enum_local_nonprimitive);
                                                     ^
c-0.3.0/kubernetes/model/v1_json_schema_props.c(961): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      example_local_object = object_parseFromJSON(example); //object
                                                  ^
c-0.3.0/kubernetes/model/v1_json_schema_props.c(1010): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      items_local_object = object_parseFromJSON(items); //object
                                                ^
c-0.3.0/kubernetes/model/v1_custom_resource_subresources.c(92): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      status_local_object = object_parseFromJSON(status); //object
                                                 ^
c-0.3.0/kubernetes/model/v1_managed_fields_entry.c(166): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      fields_v1_local_object = object_parseFromJSON(fields_v1); //object
                                                    ^
c-0.3.0/kubernetes/model/v1_watch_event.c(84): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_local_object = object_parseFromJSON(object); //object
                                                 ^
c-0.3.0/kubernetes/model/v1alpha1_storage_version.c(166): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      spec_local_object = object_parseFromJSON(spec); //object
                                               ^
c-0.3.0/kubernetes/api/CustomObjectsAPI.c(130): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(324): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(533): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(756): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1000): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1243): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1406): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1517): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1628): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1747): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1869): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(1991): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(2216): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(2569): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(2846): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(3046): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(3246): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(3454): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(3666): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(3878): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(4062): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(4239): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(4416): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(4597): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(4785): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^

c-0.3.0/kubernetes/api/CustomObjectsAPI.c(4973): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      object_t *elementToReturn = object_parseFromJSON(CustomObjectsAPIlocalVarJSON);
                                                       ^
c-0.3.0/kubernetes/model/v1_controller_revision.c(134): warning #167: argument of type "cJSON *" is incompatible with parameter of type "char *"
      data_local_object = object_parseFromJSON(data); //object
                                               ^
ityuhui commented 2 years ago

Thank you for pointing this out. We're working on this issue now.