• 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: FSMountServerVolumeAsync() in multiple threads?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FSMountServerVolumeAsync() in multiple threads?


  • Subject: Re: FSMountServerVolumeAsync() in multiple threads?
  • From: Jim Luther <email@hidden>
  • Date: Tue, 11 Aug 2009 13:56:04 -0700

This would be more appropriate on the filesystem-dev list <email@hidden >. However...

Have you written a bug report in Radar? If so, what's the Radar number? Can you give me a crash log (or is one attached to the bug report)?

As for reproducing it, are all of the server URLs you are attempting to mount AFP, or are they a mixture of filesystem types?

- Jim

On Aug 11, 2009, at 1:25 PM, Matt DeFoor wrote:

I have an application where I'm trying to mount multiple volumes in
their own thread using FSMountServerVolumeAsync(). The application is
Cocoa-based. So, I use:

[NSThread detachNewThreadSelector:@selector(mountResource:)
toTarget:self withObject:aResource]

to spawn each thread. The call to FSMountServerVolumeAsync() looks like this:

Result = FSMountServerVolumeAsync((CFURLRef)urlOfVolumeToMount, NULL,
(CFStringRef)[aResource username], (CFStringRef)[aResource password],
volumeOp, aResource, 0, mountUPP, CFRunLoopGetCurrent(),
CFSTR("MyMountMode"));

As you can tell, I'm using a callback. It handles certain aspects of
what is returned. When, I have only one thread, things work fine; the
callback is called and the volume is mounted. When I have more than
one volume to mount (ergo, more than one thread is calling
FSMountServerVolumeAsync()) varying results are produced. For example,
the return code from FSMountServerVolumeAsync() might be -50. Or there
might be an exception (EXC_BAD_ACCESS) in one of the functions that
FSMountServerVolumeAsync() calls (e.g. TAFPSession::AFPLogout).

Has anyone had success using FSMountServerVolumeAsync() in this manner?

Is there a better approach to FSMountServerVolumeAsync()'s usage?

Thanks,
Matt

_______________________________________________ Do not post admin requests to the list. They will be ignored. Macnetworkprog mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: FSMountServerVolumeAsync() in multiple threads?
      • From: Matt DeFoor <email@hidden>
References: 
 >FSMountServerVolumeAsync() in multiple threads? (From: Matt DeFoor <email@hidden>)

  • Prev by Date: FSMountServerVolumeAsync() in multiple threads?
  • Next by Date: Re: FSMountServerVolumeAsync() in multiple threads?
  • Previous by thread: FSMountServerVolumeAsync() in multiple threads?
  • Next by thread: Re: FSMountServerVolumeAsync() in multiple threads?
  • Index(es):
    • Date
    • Thread