C (130/304)

From:Damir Arh
Date:14 Aug 2000 at 15:30:25
Subject:Re: Passing a ptr

Hello!

> Ok, I tried the following but it doesn't work. I am assuming I am
> not addressing the variables in the correct way within the funtion.
> Here's what I am doing:

Well, you mentioned in the next mail that you stopped trying to do it this
way, but I'd still like to warn you about something:

> if (*array = (mystruct **) AllocVec ( arraysize * sizeof (mystruct)))

Shouldn't you be using 'sizeof(mystruct *)' as you are actually allocating
an array of pointers to mystruct and not an array of mystructs if I am not
mistaking.

Kind regards



Damir Arh, programmer
Windows and Amiga developer
Visit: http://damir.gajba.net/