I would like to declare a pointer to a pointer in objective-c.
I have an instance variable (primaryConnection) that should be updated dynamically to point to a local variable when it changes.
NSURLConnection *primaryConnection;
-(void) doSomething
{
NSURLConnection *conn;
primaryConnection = conn;
conn = // set by something else
// primaryConnection should now reflect the pointer that conn is pointing to, set by something else... but it doesn't?
}
Is it possible to declare a pointer to a pointer somehow? Or am I missing something?