Try putting an * after both uses of "char". CStrings (char arrays) are char pointers.
Dave On Thu, Aug 21, 2008 at 6:42 AM, Stuart Green <[EMAIL PROTECTED]> wrote: > Hi, > > I'm either overlooking something extremely simple here or I'm losing my > mind. > > I have two NSString objects in a NSDictionary object that I am passing to a > class method in the form: > > (int)validateUsersFor:(NSString *)username withEmailAddress:(NSString > *)email > > Within the function, I need to convert the NSStrings back to C Strings (for > a C API) so I'm using: > > const char cUserName = [username UTF8String]; > const char cEmail = [email UTF8String]; > > However, come the build, I get > > warning: initialization makes integer from pointer without a cast > > I thought I was doing everything right. Any ideas? > > Cheers, > > Stu > _______________________________________________ > > Cocoa-dev mailing list ([email protected]) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/cocoa-dev/davedelong%40gmail.com > > This email sent to [EMAIL PROTECTED] > _______________________________________________ Cocoa-dev mailing list ([email protected]) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
