?

Log in

No account? Create an account

Previous Entry | Next Entry

Bug in LJ Controller

LiveJournalController::sendString:

if ((lookup !=1) || (success != 1) {
	// Brings up Error panel (Should be a sheet)
	// returns nil (Expects NSString*)
}

Upon entering LiveJournalController::buildDictionary:
NSString *httpResult; shows non nil initialization. (0x2)

scanner = [NSScanner scannerWithString: inputString]
// properly initializes even though inputString == nil

HOWEVER:

[scanner scanUpToString: @"\n" intoString &httpResult];

Does _not_ change httpResult. Which is still non-nil

a non nil value sent a message, seems to try to execute it.
thus the following [httpResult isEqualToString: @""]

Thus:
Unable to determine target of Objective-C method call (ignoring):
Cannot access memory at address 0x2

[Error: Irreparable invalid markup ('<signal:>') in entry. Owner must fix manually. Raw contents below.]

<PRE>
LiveJournalController::sendString:

if ((lookup !=1) || (success != 1) {
// Brings up Error panel (Should be a sheet)
// returns nil (Expects NSString*)
}

Upon entering LiveJournalController::buildDictionary:
NSString *httpResult; shows non nil initialization. (0x2)

scanner = [NSScanner scannerWithString: inputString]
// properly initializes even though inputString == nil

HOWEVER:

[scanner scanUpToString: @"\n" intoString &httpResult];

Does _not_ change httpResult. Which is still non-nil

a non nil value sent a message, seems to try to execute it.
thus the following [httpResult isEqualToString: @"<foo>"]

Thus:
Unable to determine target of Objective-C method call (ignoring):
Cannot access memory at address 0x2

<Signal: "EXC_BAD_ACCESS">

I tried setting at the beginning of buildDirectory
NSString *httpResult = nil;

However, now the error occurs on the following NSRunAlertPanel
which wants to send httpResult into the alert panel as an argument that's required to be a string.

New logic needs to be placed in to pull the nil case away from the net-alive/bad server case.
</PRE>

Comments

( 1 comment — Leave a comment )
cryo
Dec. 30th, 2001 04:57 am (UTC)
Reasonable. I have buildDictionary now check for a nil string and just return, all the following checks for buildDictionary results -should- just fail somewhat gracefully.
( 1 comment — Leave a comment )

Profile

ijournal
iJournal: Official LiveJournal Client for Mac OS X
iJournal Home

Latest Month

January 2012
S M T W T F S
1234567
891011121314
15161718192021
22232425262728
293031    

Page Summary

Powered by LiveJournal.com
Designed by Lilia Ahner