iSqueak Wikki : vmPathGetLength

HomePage :: Categories :: PageIndex :: RecentChanges :: RecentlyCommented :: Login/Register

Revision [226]

The oldest known version of this page was edited on 2008-10-17 02:55:29 by JohnMcIntosh

sqInt vmPathGetLength(sqInt sqVMPathIndex, sqInt length)


Parms:
sqVMPathIndex pointer to storage for name
length is length of string in bytes, this is pre-calculated by calling vmPathSize.

return: NONE, fake return of zero
From: Interpreter primitiveVMPath
Why:
get vm path name

Responsibility:

MacIntosh
os-9/OSXCarbon
Invoke getImageNameWithEncoding, but then also check length of image name versus length parm for errors.

Cocoa:
TBD

iPhone
Use strncpy(sqImageName, [self getVMPath], length);
where getVMPath uses UTF8String of vmPathStringURL
tack on missing '/'

Unix
copy bytes from vmPath, cross check strlen with length

Windows
copy bytes from vmPath, cross check strlen with length

BUGS
Disagreement about encoding
Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by WikkaWiki
Page was generated in 0.0381 seconds