> On 8 Oct 2016, at 11:22, Quincey Morris
> wrote:
>
> On Oct 7, 2016, at 21:06 , Gerriet M. Denkmann wrote:
>>
>> But, alas, it is also much slower: overhead almost 40 sec (whereas my
>> admittedly rather hackish way took less then
On Oct 7, 2016, at 21:06 , Gerriet M. Denkmann wrote:
>
> But, alas, it is also much slower: overhead almost 40 sec (whereas my
> admittedly rather hackish way took less then half a second).
That may indicate a lot of contention — e.g. you were running multiple copies
of
> On 8 Oct 2016, at 05:01, Quincey Morris
> wrote:
>
> On Oct 7, 2016, at 07:49 , Gerriet M. Denkmann wrote:
>>
>> Is there a better way than this:
>> dsema = dispatch_semaphore_create( 0 );
>>
>> some loop to be counted
> On 7 Oct 2016, at 23:18, Jens Alfke wrote:
>
>
>> On Oct 7, 2016, at 7:56 AM, Gerriet M. Denkmann wrote:
>>
>> Some app with NSLog (not running in Xcode) does not show anything in
>> Console.app.
>> Only when Iog in as administrator I can see the
On Oct 7, 2016, at 02:28 , J.E. Schotsman wrote:
>
> It isn’t mentioned in the NSProgress Overview though.
You are correct about that, which makes me wonder how much of my understanding
I simply dreamed.
Looking at the documentation a bit more carefully, though, I think
On Oct 7, 2016, at 15:37 , Dave Fernandes wrote:
>
> But I don’t see how incrementing it after creating it is any different from
> creating it with a non-zero count. Either way, if you have resources
> available, the count will be non-zero, and you will crash if you
Thanks a lot or your quick response!
>> I would at least attributesOfItemAtPath:error expect to show
>> NSFileTypeSymbolicLink for the aliases and symlinks.
>
> No, aliases are files, not symbolic links. Symbolic links are a special
> category of file system objects in a Unix-compatible file
>
> In practice, you’d actually initialize the semaphore like this:
>
>> dsema = dispatch_semaphore_create (0); // start with a zero count
>> dispatch_semaphore_signal (dsema); // increment to the number of
>> resources in the pool.
>
> That’s because if you create the semaphore with
On Oct 7, 2016, at 08:21 , Gabriel Zachmann wrote:
>
> [NSNumber numberWithBool: YES] == [fattrs objectForKey: NSFileExtensionHidden]
Also, this is really bad. These are objects, and there’s no guarantee that the
object pointers are identical, which is what you’re testing
On Oct 7, 2016, at 08:21 , Gabriel Zachmann wrote:
>
> I would at least attributesOfItemAtPath:error expect to show
> NSFileTypeSymbolicLink for the aliases and symlinks.
No, aliases are files, not symbolic links. Symbolic links are a special
category of file system
On Oct 7, 2016, at 07:49 , Gerriet M. Denkmann wrote:
>
> Is there a better way than this:
> dsema = dispatch_semaphore_create( 0 );
>
> some loop to be counted
> {
> dispatch_semaphore_signal(dsema);
> ….
> }
>
> NSUInteger counter = 0;
>
I am trying to enumerate the contents of a directory (aka folder) using
NSDirectoryEnumerator.
My problem is that the file attributes always returns NSFileTypeRegular,
no matter whether it is an alias/symlink or a regular file.
You can see my code below.
I have tried to retrieve the file
I am doing Spotlight searches using the NSMetadataQuery API.
Usually, my search is limited to a specific folder.
Is it possible to make it follow aliases (and symlinks) that might exist in
that folder?
I am especially interested in aliases/symlinks that point to other folders.
Or do I have to
For some mysterious reason our SPDY encrypted proxy fails in our chromium
based browser only in Mac OS X Sierra. It works fine in every other
operating system. We're getting a "CERTIFICATE_INVALID_ERROR" even though
our certificates are of course fine.
If you have any idea what's causing this,
On Fri, Oct 7, 2016, at 11:24 AM, Jens Alfke wrote:
>
> > On Oct 7, 2016, at 1:14 AM, Quincey Morris
> > wrote:
> >
> > One straightforward way is to use dispatch_semaphore. IIRC it’s lightweight
> > unless it blocks (that is, unless its count is zero
On Oct 7, 2016, at 09:24 , Jens Alfke wrote:
>
> IMO dispatch_semaphore is overkill for this; it’s not just an atomic counter,
> it’s also got blocking behaviors for use in e.g. managing a pool of resources.
I wasn’t suggesting using dispatch_semaphore itself as the atomic
> On Oct 7, 2016, at 1:14 AM, Quincey Morris
> wrote:
>
> One straightforward way is to use dispatch_semaphore. IIRC it’s lightweight
> unless it blocks (that is, unless its count is zero when you wait), so it’s
> good for this situation where actual
> On Oct 7, 2016, at 7:56 AM, Gerriet M. Denkmann wrote:
>
> Some app with NSLog (not running in Xcode) does not show anything in
> Console.app.
> Only when Iog in as administrator I can see the NSLog lines.
Huh, you’re right…
The Console app’s help has a link to developer
On 7 Oct 2016, at 08:19, Gerriet M. Denkmann wrote:
> So what is the proper way to count something atomicly and undeprecatedly?
or is the approved source for this kind of thing.
In C++, you might write
#include
std::atomic counter;
then you can just do
Some app with NSLog (not running in Xcode) does not show anything in
Console.app.
Only when Iog in as administrator I can see the NSLog lines.
Is this working as expected?
Can anything be done to make common people see the NSLog lines too?
Gerriet.
> On 7 Oct 2016, at 15:14, Quincey Morris
> wrote:
>
> On Oct 7, 2016, at 00:19 , Gerriet M. Denkmann wrote:
>>
>> So what is the proper way to count something atomicly and undeprecatedly?
>
> One straightforward way is to use
> On 7 Oct 2016, at 15:43, Ken Thomases wrote:
>
> On Oct 7, 2016, at 2:19 AM, Gerriet M. Denkmann wrote:
>>
>> I need (just for debugging purposes) to count something in a thread safe
>> way.
>> […]
>> So I tried OSIncrementAtomic.
>> Now I get:
> On 07 Oct 2016, at 11:37, dangerwillrobinsondan...@gmail.com wrote:
>
> Go to the inspector palette on the right side.
> With the relevant item selected you will be able to disconnect things.
Oh, I see. You just need to hit the the little cross.
BTW I meant editing the xib file of course.
Go to the inspector palette on the right side.
With the relevant item selected you will be able to disconnect things.
Sent from my iPhone
> On 7 Oct 2016, at 18:31, J.E. Schotsman wrote:
>
> Hello,
>
> I haven’t found a way yet to delete actions, outlets etc. using the
Hello,
I haven’t found a way yet to delete actions, outlets etc. using the xib
interface.
I’ve resorted to editing the project bundle with a text editor. Surely that
isn’t the way this is supposed to be done?
Any pointers appreciated.
Jan E.
___
> On 06 Oct 2016, at 22:43, Quincey Morris
> wrote:
>
> Well, Apple has. NSProgress is a multi-purpose class, one of whose purposes
> is to provide a thread-safe way of trampolining the progress completion
> reports from a background worker thread to
> On 06 Oct 2016, at 20:46, Ken Thomases wrote:
>
> When you are using bindings, you must ensure that changes to the properties
> to which UI is bound happen only on the main thread. Depending on your
> design, you can often do something like:
>
>
On Oct 7, 2016, at 2:19 AM, Gerriet M. Denkmann wrote:
>
> I need (just for debugging purposes) to count something in a thread safe way.
> […]
> So I tried OSIncrementAtomic.
> Now I get: "Implicit declaration of function 'OSIncrementAtomic' is invalid
> in C99" and the
On Oct 7, 2016, at 00:19 , Gerriet M. Denkmann wrote:
>
> So what is the proper way to count something atomicly and undeprecatedly?
One straightforward way is to use dispatch_semaphore. IIRC it’s lightweight
unless it blocks (that is, unless its count is zero when you wait),
I need (just for debugging purposes) to count something in a thread safe way.
This works, but is deprecated:
SInt32 counter;
- (IBAction)doSomething:sender
{
counter = 0;
some loop
{
IncrementAtomic( );// 'IncrementAtomic' is
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
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:
31 matches
Mail list logo