Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Mumps > GT.M V52FT01 Ca...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 2 Topic 866 of 959
Post > Topic >>

GT.M V52FT01 Call-in example problem

by stuffduff <stuffduff@[EMAIL PROTECTED] > Jun 4, 2007 at 09:33 AM

Hi,

Running V52FT01 sourceforge binary installed in /opt/gtm/V52FT01.
mumps -direct works as expected.

I have compiled the call-in example on fedora core 6 as follows:

gcc -Os -Wall -c main.c -I. -I/opt/gtm/V52FT01

linked:

gcc main.o -o test1 -L/opt/gtm/V52FT01 -lgtmshr -lc

set the env var:

export GTMCI=`pwd`/calltab.ci

run:

../test1

output:

srcstr = /opt/library/V43001E
$piece(/opt/library/V43001E,"/",4) is V43001E
After set $piece(srcstr,"/",4) = V44002
srcstr = /opt/library/V44002

then I get back to a command prompt in the gnome terminal session, but
the terminal session is corrupt. If I hit enter everything shows up on
a single line and I can't type anything else in that terminal. I can
reset it, but the only thing that works is to close that session and
start a new one.

[stuffduff@[EMAIL PROTECTED]
 ~]$ cd Desktop/GT.M-python/
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$ export GTMCI=`pwd`/calltab.ci
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$ ./test1
srcstr = /opt/library/V43001E
$piece(/opt/library/V43001E,"/",4) is V43001E
After set $piece(srcstr,"/",4) = V44002
srcstr = /opt/library/V44002
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$ [stuffduff@[EMAIL PROTECTED]
 GT.M-python]$
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$ [stuffduff@[EMAIL PROTECTED]
 GT.M-python]$
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$ [stuffduff@[EMAIL PROTECTED]
 GT.M-python]$
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$ [stuffduff@[EMAIL PROTECTED]
 GT.M-python]$
[stuffduff@[EMAIL PROTECTED]
 GT.M-python]$

So I made a simplified version:

#include <stdio.h>
#include "gtmxc_types.h"
#define BUF_LEN 1024
int main()
{
gtm_char_t msgbuf[BUF_LEN], dststr[100];
gtm_char_t srcstr[] = "/opt/library/V43001E";
gtm_status_t status;

printf("srcstr = %s\n", srcstr);

return 0;
}

Which I compiled and ran. The output was as expected and the terminal
window continued to function normally. So I added back the init & exit
w/o any other calls:

#include <stdio.h>
#include "gtmxc_types.h"
#define BUF_LEN 1024
int main()
{
gtm_char_t msgbuf[BUF_LEN], dststr[100];
gtm_char_t srcstr[] = "/opt/library/V43001E";
gtm_status_t status;

status = gtm_init();
if (status != 0)
{
gtm_zstatus(msgbuf, BUF_LEN);
return status;
}

printf("srcstr = %s\n", srcstr);

status = gtm_exit();
if (status != 0)
{
gtm_zstatus(msgbuf, BUF_LEN);
fprintf(stderr, "%s\n", msgbuf);
return status;
}

return 0;
}

This time I reproduced the error as before.

So I believe that somewhere in the interaction with the call-in
interface some extra control characters are getting generated and
causing the problem. Since there is no indication of an OPEN or USE
command in the m example, thinking that the call-in functionality
works by calling the 'm' functionality by it's underlying 'C' code
interface. So at this point I'm not really sure how to go about
debugging this.

Would building GT.M on my platform be the way to address this
problem?

Any suggestions sincerely appreciated,

Sean




 2 Posts in Topic:
GT.M V52FT01 Call-in example problem
stuffduff <stuffduff@[  2007-06-04 09:33:13 
Re: GT.M V52FT01 Call-in example problem
"K.S. Bhaskar"   2007-06-07 03:28:08 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed May 14 8:54:49 CDT 2008.