~ubuntu-branches/ubuntu/karmic/gnustep-base/karmic

« back to all changes in this revision

Viewing changes to Source/objc-load.m

  • Committer: Bazaar Package Importer
  • Author(s): Luca Falavigna
  • Date: 2008-07-05 09:49:51 UTC
  • mfrom: (1.2.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20080705094951-gs19i3erqo2xx6if
Tags: 1.16.1-2ubuntu1
* Merge from Debian unstable, remaining Ubuntu changes:
  + debian/rules:
    - Add lpia to ALL_ARCHS supported architectures.
  + debian/control:
    - Add lpia architecture where needed.
  + debian/control{,.m4}:
    - Update Maintainer field as per spec.

Show diffs side-by-side

added added

removed removed

Lines of Context:
9
9
   This library is free software; you can redistribute it and/or
10
10
   modify it under the terms of the GNU Lesser General Public
11
11
   License as published by the Free Software Foundation; either
12
 
   version 3 of the License, or (at your option) any later version.
 
12
   version 2 of the License, or (at your option) any later version.
13
13
 
14
14
   This library is distributed in the hope that it will be useful,
15
15
   but WITHOUT ANY WARRANTY; without even the implied warranty of
260
260
GSPrivateSymbolPath(Class theClass, Category *theCategory)
261
261
{
262
262
  unichar buf[MAX_PATH];
 
263
  NSString *s = nil;
263
264
  MEMORY_BASIC_INFORMATION memInfo;
264
265
  NSCAssert(!theCategory, @"GSPrivateSymbolPath doesn't support categories");
265
266
 
266
267
  VirtualQueryEx(GetCurrentProcess(), theClass, &memInfo, sizeof(memInfo));
267
268
  if (GetModuleFileNameW(memInfo.AllocationBase, buf, sizeof(buf)))
268
269
    {
269
 
      return [NSString stringWithCharacters: buf length: wcslen(buf)];
 
270
      s = [NSString stringWithCharacters: buf length: wcslen(buf)];
270
271
    }
271
 
  return 0;
 
272
  return s;
272
273
}
273
274
#else
274
275
NSString *