• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Still having problume with Security API
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Still having problume with Security API


  • Subject: Re: Still having problume with Security API
  • From: Guy Winslow <email@hidden>
  • Date: Wed, 16 May 2001 11:57:00 -0700

on 5/16/01 8:15 AM, Ryan Dary at email@hidden wrote:

> Actually, when you call the AuthorizationExecuteWithPrivileges, it must
> be altering the argv array that is passed in because you don't need to
> pass it the path to the program as the first arg, as might be expected.
> The program being executed will still receive the path as the first [0]
> arg.
>
> - Ryan
>
>
> On Tuesday, May 15, 2001, at 04:15 PM, email@hidden wrote:
>
>> On Wednesday, May 16, 2001, at 12:56 AM, Ryan Dary wrote:
>>
>>>> Your argv doesn't have a NULL termination:
>>>>
>>>> char * argv[3];
>>>>
>>>> [...]
>>>>
>>>> argv[0] = SOURCE;
>>>> argv[1] = DESINATION;
>>>> argv[2] = NULL;
>>>>
>>>> Try adding that..
>>>>
>>>> - Ryan
>>
>> argv[0] should be the application name, so it's something like:
>>
>> char *argv[4];
>>
>> argv[0]=PROGRAM; // "cp"
>> argv[1]=SOURCE;
>> argv[2]=DESTINATION;
>> argv[3]=NULL;
>> --
>> Pelle Johansson
>> <email@hidden>
>> _______________________________________________
>> cocoa-dev mailing list
>> email@hidden
>> http://www.lists.apple.com/mailman/listinfo/cocoa-dev
> _______________________________________________
> cocoa-dev mailing list
> email@hidden
> http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Ok Fingerd it out. I was using the remove command to clean up after the cp
command was dune. The file i was removing was the SOURCE peramater in the
cp command. Forgot it was not blocking. Sary to pollute list. It was one
of though's things you rip your hare out over.


References: 
 >Re: Still having problume with Security API (From: Ryan Dary <email@hidden>)

  • Prev by Date: Re: Still having problume with Security API
  • Next by Date: Re: wrapping text in an NSTextView
  • Previous by thread: Re: Still having problume with Security API
  • Next by thread: mp3 streaming?
  • Index(es):
    • Date
    • Thread