@@ -53,11 +53,11 @@ handle: handle] autorelease]; } - init { - Class c = isa; + Class c = [self class]; [self release]; @throw [OFNotImplementedException exceptionWithClass: c selector: _cmd]; } @@ -96,11 +96,11 @@ port = ntohs(rdata[2]); if (dn_expand(ns_msg_base(handle), ns_msg_end(handle), (uint8_t*)&rdata[3], buffer, NS_MAXDNAME) < 1) @throw [OFInitializationFailedException - exceptionWithClass: isa]; + exceptionWithClass: [self class]]; target = [[OFString alloc] initWithCString: buffer encoding: OF_STRING_ENCODING_NATIVE]; } @catch (id e) { @@ -118,14 +118,13 @@ [super dealloc]; } - (OFString*)description { - return [OFString stringWithFormat: @"<%@ priority: %" PRIu16 - @", weight: %" PRIu16 - @", target: %@:%" PRIu16 @">", - isa, priority, weight, target, port]; + return [OFString stringWithFormat: + @"<%@ priority: %" PRIu16 @", weight: %" PRIu16 @", target: %@:%" + PRIu16 @">", [self class], priority, weight, target, port]; } - (uint16_t)priority { return priority; @@ -206,11 +205,11 @@ ns_rr resourceRecord; ns_msg handle; if (res_ninit(&resState)) @throw [OFAddressTranslationFailedException - exceptionWithClass: isa + exceptionWithClass: [self class] socket: nil host: domain]; answer = [self allocMemoryWithSize: of_pagesize]; answerLen = res_nsearch(&resState, [request cStringWithEncoding: @@ -221,18 +220,18 @@ (h_errno == NO_DATA))) return; if (answerLen < 1 || answerLen > of_pagesize) { @throw [OFAddressTranslationFailedException - exceptionWithClass: isa + exceptionWithClass: [self class] socket: nil host: domain]; } if (ns_initparse(answer, answerLen, &handle)) @throw [OFAddressTranslationFailedException - exceptionWithClass: isa + exceptionWithClass: [self class] socket: nil host: domain]; resourceRecordCount = ns_msg_count(handle, ns_s_an); for (i = 0; i < resourceRecordCount; i++) {