From: helge Date: Mon, 28 May 2007 14:49:15 +0000 (+0000) Subject: fixed a gstep-base issue X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2afe19d91f4d52c499e4772bd2f5f8290874c649;p=sope fixed a gstep-base issue git-svn-id: http://svn.opengroupware.org/SOPE/trunk@1490 e4a50df8-12e2-0310-a44c-efbce7f8a7e3 --- diff --git a/sope-core/NGExtensions/FdExt.subproj/NSString+Encoding.m b/sope-core/NGExtensions/FdExt.subproj/NSString+Encoding.m index 9615b59f..b1812587 100644 --- a/sope-core/NGExtensions/FdExt.subproj/NSString+Encoding.m +++ b/sope-core/NGExtensions/FdExt.subproj/NSString+Encoding.m @@ -32,6 +32,7 @@ // TODO: should move different implementations to different files ... + #if NeXT_Foundation_LIBRARY || COCOA_Foundation_LIBRARY @interface NSString(Encoding_PrivateAPI) @@ -72,8 +73,10 @@ @end /* NSString(Encoding) */ + #else /* ! NeXT_Foundation_LIBRARY */ + @implementation NSString(Encoding) #ifdef __linux__ diff --git a/sope-mime/ChangeLog b/sope-mime/ChangeLog index 38a9085e..b27a3278 100644 --- a/sope-mime/ChangeLog +++ b/sope-mime/ChangeLog @@ -1,5 +1,7 @@ 2007-05-28 Helge Hess + * NGMime: fixed compilation on gnustep-base (v4.7.247) + * NGMime: improved text body encoding (v4.7.246) 2007-05-15 Wolfgang Sourdeau diff --git a/sope-mime/NGMime/ChangeLog b/sope-mime/NGMime/ChangeLog index 64724089..8f6b30a7 100644 --- a/sope-mime/NGMime/ChangeLog +++ b/sope-mime/NGMime/ChangeLog @@ -1,3 +1,7 @@ +2007-05-28 Helge Hess + + * NGMimeTextBodyGenerator.m: fixed compilation on gnustep-base + 2007-05-28 Helge Hess * NGMimeTextBodyGenerator.m: reworked body contents encoding using the diff --git a/sope-mime/NGMime/NGMimeTextBodyGenerator.m b/sope-mime/NGMime/NGMimeTextBodyGenerator.m index 2369ae95..a535dcc7 100644 --- a/sope-mime/NGMime/NGMimeTextBodyGenerator.m +++ b/sope-mime/NGMime/NGMimeTextBodyGenerator.m @@ -22,6 +22,7 @@ #include "NGMimeBodyGenerator.h" #include "NGMimePartGenerator.h" +#include #include "common.h" @implementation NGMimeTextBodyGenerator @@ -81,8 +82,13 @@ NSStringEncoding encoding = 0; NSString *charset = [[_part contentType] valueOfParameter:@"charset"]; - if ([charset isNotEmpty]) - encoding = [NSString stringEncodingForEncodingNamed:charset]; + if ([charset isNotEmpty]) { +#if NeXT_Foundation_LIBRARY || COCOA_Foundation_LIBRARY + encoding = (NSString *)[NSString stringEncodingForEncodingNamed:charset]; +#else + encoding = [self _encodingFromContentType:[_part contentType]]; +#endif + } data = [body dataUsingEncoding: (encoding != 0 ? encoding : NSISOLatin1StringEncoding)]; diff --git a/sope-mime/Version b/sope-mime/Version index 160886bc..83332567 100644 --- a/sope-mime/Version +++ b/sope-mime/Version @@ -2,7 +2,7 @@ MAJOR_VERSION:=4 MINOR_VERSION:=7 -SUBMINOR_VERSION:=246 +SUBMINOR_VERSION:=247 # v4.5.214 requires libNGExtensions v4.5.146 # v4.2.149 requires libNGStreams v4.2.34