Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. indieboy

    malloc inside a function

    thanks a lot, but then i have another question, what if i would like to allocate memory for 2 different structs in the same function? is it impossible? do i have to return it? i thought that passing the structs trough pointers, i would be allocating memory for the original variable. i just...
  2. indieboy

    malloc inside a function

    could anyone tell me what's wrong about the use of pointers and malloc. =) in function alloc_memory the memory is allocated just fine, but when it returns, the pointers test and test->test are 0x00 =((( #include <stdio.h> #include <stdlib.h> typedef struct { char *value1; char *value2...

Part and Inventory Search

Back
Top