Advertisement
Guest User

Untitled

a guest
May 25th, 2019
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.37 KB | None | 0 0
  1.     int count = 5;
  2.  
  3.     int16_t * i16Ptr0 = (int16_t*)malloc(count * sizeof(int16_t));
  4.     int16_t * i16Ptr1 = (int16_t*)calloc(count, sizeof(int16_t));
  5.     int16_t * i16Ptr2 = (int16_t*)memset(i16Ptr0, 1111, count * sizeof(int16_t));
  6.     int16_t * i16Ptr3 = (int16_t*)realloc(i16Ptr2, (count + 2) * sizeof(int16_t));
  7.  
  8.     free(i16Ptr0);
  9.     free(i16Ptr1);
  10.     free(i16Ptr2);
  11.     free(i16Ptr3);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement