mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 16:50:58 +00:00
Hack to read /proc filesystem
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@10311 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
927e64252e
commit
14c68f4793
3 changed files with 71 additions and 18 deletions
|
@ -6,8 +6,14 @@
|
|||
int main ()
|
||||
{
|
||||
id pool = [NSAutoreleasePool new];
|
||||
id o = [NSObject new];
|
||||
id o = [NSObject new];
|
||||
printf ("Hello from object at 0x%x\n", (unsigned)[o self]);
|
||||
|
||||
o = [NSString stringWithFormat: @"/proc/%d/status", getpid()];
|
||||
NSLog(@"'%@'", o);
|
||||
o = [NSString stringWithContentsOfFile: o];
|
||||
NSLog(@"'%@'", o);
|
||||
|
||||
exit (0);
|
||||
}
|
||||
#else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue