Update of /cvsroot/pure-data/externals/moocow/pdstring/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23212/src
Modified Files:
string2any.c
Log Message:
+ fixed any2string/string2any asymmetry for default case eos_char<0
Index: string2any.c
===================================================================
RCS file: /cvsroot/pure-data/externals/moocow/pdstring/src/string2any.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** string2any.c 3 Aug 2007 13:15:38 -0000 1.3
--- string2any.c 19 Oct 2007 13:32:56 -0000 1.4
***************
*** 88,92 ****
{
char *s;
! int x_argc, a_argc=argc;
t_atom *x_argv;
--- 88,92 ----
{
char *s;
! int x_argc, a_argc=0;
t_atom *x_argv;
***************
*** 99,104 ****
/*-- get text --*/
! for (s=x->x_text; argc > 0; argc--, argv++, s++) {
*s = atom_getfloat(argv);
}
*s = 0;
--- 99,106 ----
/*-- get text --*/
! for (s=x->x_text; argc > 0; argc--, a_argc++, argv++, s++) {
*s = atom_getfloat(argv);
+ S2ADEBUG(post("string2any[%p]: a_argc=%d,*s=%d", x, a_argc, *s));
+ if ((x->x_eos<0 && !*s) || (*s==x->x_eos)) { break; } /*-- hack: look for eos char --*/
}
*s = 0;