<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=US-ASCII">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2653.12">
<TITLE>Passing strings to a plugin</TITLE>
</HEAD>
<BODY>
<P><FONT SIZE=2>Hi</FONT>
</P>
<P><FONT SIZE=2>I have a plugin as follows:</FONT>
</P>
<P><FONT SIZE=2>run: hostApi inDev: inDeviceName outDev: outDeviceName rate: sampleRate frames: frames latency: latency </FONT>
</P>
<P> <FONT SIZE=2>self export: true.</FONT>
</P>
<P> <FONT SIZE=2>self primitive: 'run'</FONT>
<BR> <FONT SIZE=2>parameters:#(String String String SmallInteger SmallInteger SmallInteger).</FONT>
</P>
<P> <FONT SIZE=2>(self</FONT>
<BR> <FONT SIZE=2>cCode: 'sdrOpenMainStream(hostApi, inDeviceName, outDeviceName, sampleRate, frames, latency)'</FONT>
<BR> <FONT SIZE=2>inSmalltalk: [false])</FONT>
<BR> <FONT SIZE=2>ifFalse: [^ interpreterProxy primitiveFail].</FONT>
</P>
<P><FONT SIZE=2>When I look at the parameters on the C side the strings are sometimes correct (depending on their length and content) and sometimes have rubbish after them like the terminator is missing. The integers are always ok. Do I have to explicitly terminate the strings?</FONT></P>
<P><FONT SIZE=2>Thanks for any help.</FONT>
</P>
<P><FONT SIZE=2>Bob</FONT>
</P>
<P><STRONG>*** Confidentiality Notice ***</STRONG>
Proprietary/Confidential<BR>Information belonging to CGI Group Inc. and its
affiliates<BR>may be contained in this message. If you are not a
recipient<BR>indicated or intended in this message (or responsible
for<BR>delivery of this message to such person), or you think for<BR>any reason
that this message may have been addressed to you<BR>in error, you may not use or
copy or deliver this message<BR>to anyone else. In such case, you should
destroy this<BR>message and are asked to notify the sender by reply
email.</P>
</BODY>
</HTML>