Re: Notification when network volume disappears

2010-06-14 Thread mm w
no you are in the weed there On Mon, Jun 14, 2010 at 9:40 AM, Boris Prohaska wrote: > Thats exactly the problem. IF the OS was aware of it, then there would be no > problem. There is also no setting for timeouts etc when performing blocking > operations onto the filesystem. > Maybe that is a OS

Re: Notification when network volume disappears

2010-06-14 Thread mm w
I don't know which kind of connection you want to observe, but basically SCNetwork and SCNetworkReachability are your friends. then control these (and get the right conf) using two callback handlers use NSWorkspace to get your entry and your exit (if this case happens) NSWorkspaceDidMountNotif

Re: How to debug invalidated core data object

2010-06-14 Thread mm w
Hello, you might place some breakpoints, you did only post the consequences, debugging is matter of understanding. On Sun, Jun 13, 2010 at 8:49 AM, Gideon King wrote: > I have a situation where I create a temporary managed object context and do a > bunch of things with various managed objects

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
and to close this: I will open the discussion: in a cpp program I will use a type-recasting behaviour on a circular ref ? Cheers! On Sun, Mar 22, 2009 at 5:26 PM, mm w wrote: > ref my previous email, > > anyway there are other aspects and side effects due to the circular > refs,

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
s, see my previous comment on symptoms and consequences Cheers! On Sun, Mar 22, 2009 at 4:53 PM, mm w wrote: > On Sun, Mar 22, 2009 at 4:32 PM, David Melgar wrote: >> Some people do that to try and impress. >> I'm not impressed. >> No useful information. >> >

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
s > On Mar 22, 2009, at 7:22 PM, Clark Cox wrote: > >> It's not very conducive to conversation to make claims, and then >> refuse to back them up, and leave it at "I let you discover it". >> >> On Sun, Mar 22, 2009 at 4:19 PM, mm w wrote: >>> &

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
let you discover it". > > On Sun, Mar 22, 2009 at 4:19 PM, mm w wrote: >> maybe in your world, anyway there are a bunch of reasons to avoid circular >> refs >> I let you discover it >> >> Cheers! >> >> On Sun, Mar 22, 2009 at 3:58 PM, Clark Cox

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
maybe in your world, anyway there are a bunch of reasons to avoid circular refs I let you discover it Cheers! On Sun, Mar 22, 2009 at 3:58 PM, Clark Cox wrote: > On Sun, Mar 22, 2009 at 3:37 PM, mm w wrote: >> Because I am like this I won't do the job for you, I will onl

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
On Sun, Mar 22, 2009 at 3:54 PM, Jean-Daniel Dupas wrote: > > Le 22 mars 09 à 23:37, mm w a écrit : > >> Because I am like this I won't do the job for you, I will only point >> you directions, that's it >> >> Google "garbage collection", it

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
refs by a "proper" design? Ok... what is "proper"? > > Generally your message alludes to many things yet provides little > information. > > On Mar 22, 2009, at 5:53 PM, mm w wrote: > >> I changed my mind, when I was writting this >> >> - (void)sen

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
I changed my mind, when I was writting this - (void)sendSharedMessage:(NSString *)msg { NSString *print = [[[NSString alloc] initWithFormat:@" %@",msg] autorelease]; NSLog(@" %@", print); } anyway it doesn't change the background On Sun, Mar 22, 2009 at 2:47

Re: Explicit release when using garbage collection with circular references

2009-03-22 Thread mm w
Hello David, your garbage collection approach is a bit naive, but not everything is wrong, you can make a google search, it will point you good resources anyway, @implementation AppDelegate - (void)sendSharedMessage:(NSString *)msg { return [[[NSString alloc] initWithFormat:@" %@",msg] autor

Re: NSString and Leaks Instrument, False Positives?

2009-03-21 Thread mm w
sorry for the extra characters that you got my iphone auto-provides me words... On Sat, Mar 21, 2009 at 5:51 PM, mm w wrote: > if you want I have a similar one with LibTiff and imageIO (10.5.6) > make a simple project with a 2 NSButton with a Tiff Image > > Cheers! > > On Sa

Re: NSString and Leaks Instrument, False Positives?

2009-03-21 Thread mm w
if you want I have a similar one with LibTiff and imageIO (10.5.6) make a simple project with a 2 NSButton with a Tiff Image Cheers! On Sat, Mar 21, 2009 at 5:33 PM, Bill Bumgarner wrote: > On Mar 21, 2009, at 5:09 PM, Kevin Ross wrote: >> >> KRStarChartMO drawPortentsInRect:circleStyle:] | +[NS

Re: NSString and Leaks Instrument, False Positives?

2009-03-21 Thread mm w
be careful with clang, sometimes is missing point, your problem is coming not from this @"Arial Bold", give the complete stack and explain what is the condition of the leak False/positive: I have an extensive use of perf tools since years and I didn't see that since a while the leak can be deeper

Re: NSData confusion

2009-03-20 Thread mm w
on the backside, for this kind of game, sometimes is good to know to use C rather than object/scalar layers, and use only an object to represent the final result. Cheers! On Fri, Mar 20, 2009 at 2:57 PM, Boyd Collier wrote: > In a program I've been developing, I make a lot of use of matrices of

Re: NSDate isEqual to...

2009-03-20 Thread mm w
Right the comment of Mike is fair, I don't know what you are doing (a lie), anyway your interest is to know a time interval rather than a date you should design a object with a referential start-time: CFAbsoluteTime timeNow(void) { return (CFAbsoluteTime) (CFAbsoluteTimeGetCurrent() - kCF

Re: NSDate isEqual to...

2009-03-20 Thread mm w
yes, see my previous message; you should NSLogged a NSDate object Cheers! On Fri, Mar 20, 2009 at 2:17 PM, Charles E. Heizer wrote: > Thanks, > No it's just playing around right now. It would be nice to be able to > specify if you wanted NSDate to be sub-second or second precision based. > > Ju

Re: NSDate isEqual to...

2009-03-20 Thread mm w
+ (BOOL)isADayEqualToAnotherDay:(NSDate*)date anotherDate:(NSDate*)anotherDate { NSCalendar *cal; NSDateComponents *componentsFromDate, *componentsFromAnotherDate; NSUInteger unitFlags = NSYearCalendarUnit | NSMonthCalendarUnit | NSDayCalendarUnit; cal = [NS

Re: Banding/smoothing problem with drawing angled gradients.

2009-03-19 Thread mm w
seriously you should think to use a GLView, you also have to think to lock your context... 2009/3/19 Phi Le : > Hello, > > I want to draw angled gradients with multiple sharp transitions using > NSGradient. I am not getting very smooth transitions between the > colors. Please take a look at my at

Re: problems with CAAnimation - SOLVED (kinda)

2009-03-19 Thread mm w
y can solve your issue you took the wrong way Cheers! On Thu, Mar 19, 2009 at 4:05 PM, Memo Akten wrote: > Hi, I've used jQuery, but I don't understand the relevance or what you mean? > > On 19 Mar 2009, at 22:30, mm w wrote: > >> you should really create a html page

Re: - (IBAction) executes normally, but then crushes.

2009-03-19 Thread mm w
There is no manual except a descent knoledge of assembly when you program You are trying to write at freed address On 3/19/09, Тимофей Даньшин wrote: > Hello again. > > Here is what is says in the debugger: > > 0 objc_msgSend > 1 NSPopAutoReleasePool > 2 -[NSApplication run] > 3 NSApplicationMai

Re: problems with CAAnimation - SOLVED (kinda)

2009-03-19 Thread mm w
you should really create a html page and play for instance with jQuery to understand how those mechanisms/API have been designed, and when you will understand what you are doing you will welcome to come again Cheers! On Thu, Mar 19, 2009 at 3:26 PM, Memo Akten wrote: > Hi Matt, thanks for lengt

Re: any recommended zip framework ?

2009-03-19 Thread mm w
if this is xml plain/text if this is bin application/octet-stream On Thu, Mar 19, 2009 at 3:02 PM, Mike Abdullah wrote: > Your problem there is that plist is Apple's semi-proprietary format. I'm > pretty certain no standard MIME type exists. You could make up your own in > accordance with the MIM

NSLog broken after call of NSTask and setStandardError

2009-03-19 Thread mm w
Hi all, this is an old message I know, but I run into the same issue, the successive answers were wrong: this is definitely a Debugger issue, this is only happens in a gdb session, the debugguer doesn't forward sighandlers then the StandardOutput is not restored, and if you run an another task jus

Re: !foo vs foo == nil

2008-08-20 Thread mm w
great alignement On Wed, Aug 20, 2008 at 8:32 PM, Clark Cox <[EMAIL PROTECTED]> wrote: > On Wed, Aug 20, 2008 at 8:06 PM, Michael Ash <[EMAIL PROTECTED]> wrote: >> On Wed, Aug 20, 2008 at 8:34 PM, Douglas Davidson <[EMAIL PROTECTED]> wrote: >>> Well, after all, zero is zero, how much difference ca

Re: !foo vs foo == nil

2008-08-20 Thread mm w
please, don't truncate my answer... especially * On Wed, Aug 20, 2008 at 8:27 PM, Clark Cox <[EMAIL PROTECTED]> wrote: > On Wed, Aug 20, 2008 at 7:44 PM, mm w <[EMAIL PROTECTED]> wrote: >> NULL does not have to be 0, 0 could be a valid pointer value > > This is not

Re: !foo vs foo == nil

2008-08-20 Thread mm w
On Wed, Aug 20, 2008 at 6:50 PM, Quincey Morris <[EMAIL PROTECTED]> wrote: > On Aug 20, 2008, at 18:15, mm w wrote: > >> as a previous oppenant said yeh dude it's normal it's undefined/ nothin >> nada :) >> >> int main(void) {g >>

Re: !foo vs foo == nil

2008-08-20 Thread mm w
uot;); return 0; } output "hello p2" On Wed, Aug 20, 2008 at 6:00 PM, mm w <[EMAIL PROTECTED]> wrote: > ok Im like a puppy I like to play, I will stop to play the evil > advogate for 98% of cases > > here my late Initialization: > we can say (!toto) is t

Re: !foo vs foo == nil

2008-08-20 Thread mm w
> -- Andrew > > On Aug 20, 2008, at 3:29 PM, mm w wrote: > >> #include >> #include >> >> int main(void) { >> char *p1; >> char *p2 = NULL; >> >> free(p1); >> >> free(p2); >> >> return

Re: !foo vs foo == nil

2008-08-20 Thread mm w
foo = -1 On Wed, Aug 20, 2008 at 5:19 PM, Clark Cox <[EMAIL PROTECTED]> wrote: > On Wed, Aug 20, 2008 at 5:07 PM, mm w <[EMAIL PROTECTED]> wrote: >> as Mike and me pointed NULL === NULL >> but Im yet not alright with >> >> (!foo) === if(foo == nil)

Re: !foo vs foo == nil

2008-08-20 Thread mm w
as Mike and me pointed NULL === NULL but Im yet not alright with (!foo) === if(foo == nil) as I sent previously #include #include int main(void) { char *p1; char *p2 = NULL; free(p1); free(p2); return 0; } On Wed, Aug 20, 2008 at 4:57 PM, Michael Ash

Re: !foo vs foo == nil

2008-08-20 Thread mm w
#define __DARWIN_NULL ((void *)0) #define nil __DARWIN_NULL typedef struct objc_object { Class isa; } *id; typedef id (*IMP)(id, SEL, ...); id is a pointer you just demonstrated that 1 = 1 On Wed, Aug 20, 2008 at 4:42 PM, Jim Puls <[EMAIL PROTECTED]> wrote: >>> Just try

Re: !foo vs foo == nil

2008-08-20 Thread mm w
and especially for someone who's developing in Java On Wed, Aug 20, 2008 at 4:15 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: > > On Aug 21, 2008, at 00:30, Filip van der Meeren wrote: > >> On 21 Aug 2008, at 00:23, Torsten Curdt wrote: >> >>> This question has come up during the last CocoaHeads a

Re: !foo vs foo == nil

2008-08-20 Thread mm w
hum (void *)0 is equal to 0 interesting... type *ptr != type *ptr= NULL you should also align your knowledge you failed, you are a lazy pointer On Wed, Aug 20, 2008 at 4:15 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: > > On Aug 21, 2008, at 00:30, Filip van der Meeren wrote: > >> On 21 Aug 20

Re: !foo vs foo == nil

2008-08-20 Thread mm w
On Wed, Aug 20, 2008 at 3:32 PM, David Duncan <[EMAIL PROTECTED]> wrote: > On Aug 20, 2008, at 3:23 PM, Torsten Curdt wrote: > >> This question has come up during the last CocoaHeads and no one was really >> able to give a definite answer. >> Do both expressions really mean the same thing (as nil i

Re: !foo vs foo == nil

2008-08-20 Thread mm w
#include #include int main(void) { char *p1; char *p2 = NULL; free(p1); free(p2); return 0; } if (toto)... just align your answer On Wed, Aug 20, 2008 at 3:23 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: > This question has come up during the last CocoaHea

Re: Parse form values from HTTP POST

2008-08-20 Thread mm w
http://developer.apple.com/samplecode/CocoaSOAP/listing7.html On Wed, Aug 20, 2008 at 1:54 PM, Jesse Grosjean <[EMAIL PROTECTED]> wrote: > Does anyone know what the best way to parse form values from and HTTP Post > is? > > I have a mini HTTP server in my app, and it needs to accept posts. I'm usi

Re: Calling an object from a C function

2008-08-19 Thread mm w
hi charlie give your code or something clearer what are you trying to do? a C object runtime? or a wrapper obj-c to C? (kidding) maybe you could have the right answers, when I read you, my feelings is that you don't go in the right direction On Tue, Aug 19, 2008 at 5:06 PM, Charlie Dickman <[EMAI

Re: Calling an object from a C function

2008-08-19 Thread mm w
did you mean: (im not sure to understand your problem) ???!!! #import int foo(int a, int b) { return (a + b); } @interface myObject: NSObject -(SInt32)aIntegertFunction:(SInt32)a plus:(SInt32)b; @end @implementation myObject -(SInt32)aIntegertFunction:(SInt32)a plus:(SInt32)b { re

Re: Including frameworks in your app bundle

2008-08-18 Thread mm w
example FRAMEWORK = MyFoo PREFIX = @executable_path/../Frameworks gcc -Wl,-single_module \ $(OBJS) \ $(LDFLAGS) \ -compatibility_version 1.0.0 \ -current_version 1.0.0 \ -install_name $(PREFIX)/$(FRAMEWORK).framework/Versions/$(VERSION)/$(FRAMEWORK) \ -dynamiclib \ -o $(FRAMEWORK) export your -

Re: Using Flex/Lex in a Cocoa project

2008-08-18 Thread mm w
if you knew flex you could understand On Mon, Aug 18, 2008 at 1:55 PM, Ricky Sharp <[EMAIL PROTECTED]> wrote: > > On Aug 18, 2008, at 3:40 PM, mm w wrote: > >> to avoid the splitting problem >> >> (c < 128) ? "%c" : "\\u%04x", c); > >

Re: Using Flex/Lex in a Cocoa project

2008-08-18 Thread mm w
to avoid the splitting problem (c < 128) ? "%c" : "\\u%04x", c); On Sat, Aug 16, 2008 at 7:43 AM, Michael Ash <[EMAIL PROTECTED]> wrote: > On Fri, Aug 15, 2008 at 10:53 PM, John Joyce > <[EMAIL PROTECTED]> wrote: >> Right now, I'm toying with using Flex/Lex in a Cocoa project. >> Unfortunately

Re: Should I retain a variable returned from this accessor?

2008-08-13 Thread mm w
no as far as possible, you shouldn't retain an accessor, you are not the owner of this accessor the accessor is owned by an the his object, you are the owner of an instance of one object when you create it for an example myobject { private dict; } string title(); ... string title() { retur

Re: Why won't Gmail cooperate with authentication delegate methods? (Gmail RSS feeds do.)

2008-08-13 Thread mm w
hi, do you use gdata obj-c client? I think it's a cookie problem, did you ask for an auth basic? On Wed, Aug 13, 2008 at 9:05 AM, Sumner Trammell <[EMAIL PROTECTED]> wrote: > (I realize that this is bordering on a Google API question, but there > is some Cocoa content.) > > > > Hi. One can whip up

Re: Accessing memory of another application?

2008-08-12 Thread mm w
Who liked to spit fire? :D as I said do not use mach primitives, I will not dive into details but it's one of worst advice you got here, spawn + run code into an exception handler do what you want with the result Cheers! On Tue, Aug 12, 2008 at 11:12 AM, Josh <[EMAIL PROTECTED]> wrote: > I've w

Re: Accessing memory of another application?

2008-08-12 Thread mm w
do not use mach primitives in your case On Tue, Aug 12, 2008 at 10:33 AM, Jean-Daniel Dupas <[EMAIL PROTECTED]> wrote: > > In practice, it's perfectly possible to access other processes memory using > public functions (it require some privileges since 10.4 intel). > But to do it you have to use t

Re: Accessing memory of another application?

2008-08-12 Thread mm w
If you 're developing the both application you can create a layer/IPC system via shm (shared memory) to communicate between your two apps, what you asked is really a newbie question regarding C programming, before trying cocoa and obj-c you should learn the base Cheers On Tue, Aug 12, 2008 at 9:

Re: When the getter returns a BOOL, is "is" the preferred prefix?

2008-08-10 Thread mm w
is or should On Fri, Aug 8, 2008 at 9:15 PM, Ken Thomases <[EMAIL PROTECTED]> wrote: > On Aug 8, 2008, at 10:53 PM, Sumner Trammell wrote: > >> We know that Cocoa strongly suggests using setFoo and foo for setters >> and getters. >> >> Sometimes I see setters and getters using the idiom setFoo and

Re: Some crash.

2008-08-02 Thread mm w
l in memory, they are not being released. > all the items report. > > anything else ? > > Sandro. > > > On 2-Aug-08, at 2:06 PM, mm w wrote: > >> maybe a retain problem >> >> On Sat, Aug 2, 2008 at 11:03 AM, Sandro Noel <[EMAIL PROTECTED]> wrote: >

Re: pointers in objective-c?

2008-08-02 Thread mm w
*(long *)obj_2->addr, obj_2->value); } return 0; } On Sat, Aug 2, 2008 at 9:50 AM, mm w <[EMAIL PROTECTED]> wrote: > Hi I'm sorry, it's not a confusion, it's only a bad knowledge of C, and > "pointers" are not understood, NS

Re: Some crash.

2008-08-02 Thread mm w
maybe a retain problem On Sat, Aug 2, 2008 at 11:03 AM, Sandro Noel <[EMAIL PROTECTED]> wrote: > Greetings, > > I don't quite know how to explain this.. :) so please excuse me if I'm not > very precise. > > In my application controller i have an object "statement" that contains an > array of "tran

Re: pointers in objective-c?

2008-08-02 Thread mm w
Hi I'm sorry, it's not a confusion, it's only a bad knowledge of C, and "pointers" are not understood, NS and what about CF or every-prefix in the world of frameworks gtk_object ... kobject ... #include long __auto_increment = 0; typedef struct { long *addr; void *value; } Obje