Skip to content

Commit

Permalink
another try
Browse files Browse the repository at this point in the history
  • Loading branch information
jcupitt committed Oct 3, 2023
1 parent ce08bef commit 637108b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/check_dicom.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,8 @@ START_TEST(test_element_CS_multivalue_empty)
uint32_t tag = 0x00080008;
uint32_t vm = 0;

char **values = malloc(vm * sizeof(char *));
// since malloc(0) can be NULL on some platforms
char **values = malloc(1);

DcmElement *element = dcm_element_create(NULL, tag, DCM_VR_CS);
(void) dcm_element_set_value_string_multi(NULL, element, values, vm, true);
Expand Down Expand Up @@ -528,7 +529,7 @@ END_TEST
START_TEST(test_element_US_multivalue_empty)
{
uint32_t tag = 0x00280010;
uint16_t value[];
uint16_t value[0];

DcmElement *element = dcm_element_create(NULL, tag, DCM_VR_US);
(void) dcm_element_set_value_numeric_multi(NULL, element, &value, 0, false);
Expand Down

0 comments on commit 637108b

Please sign in to comment.