Browse Source

Fix error in quote parsing of log entries.

tags/non-daw-v1.1.0
Jonathan Moore Liles 17 years ago
parent
commit
82ada52b71
2 changed files with 11 additions and 4 deletions
  1. +9
    -3
      Timeline/Loggable.C
  2. +2
    -1
      Timeline/Region.C

+ 9
- 3
Timeline/Loggable.C View File

@@ -103,7 +103,8 @@ parse_alist( const char *s )

char *pair = (char*)malloc( l + 1 );

if ( c[ strlen( c ) - 1 ] == ' ' )
/* remove trailing space */
if ( c[ l - 1 ] == ' ' )
--l;

strncpy( pair, c, l );
@@ -122,8 +123,13 @@ parse_alist( const char *s )
if ( *v == '"' )
{
// v++;
v[ strlen( v ) - 1 ] = '\0';
memmove( v, v + 1, strlen( v ) + 1 );
if ( v[ strlen( v ) - 1 ] != '"' )
printf( "error: invalid quoting in log entry!\n" );
else
{
v[ strlen( v ) - 1 ] = '\0';
memmove( v, v + 1, strlen( v ) + 1 );
}
}
}



+ 2
- 1
Timeline/Region.C View File

@@ -390,10 +390,11 @@ Region::handle ( int m )
_fade_in.type = (Fade::fade_type_e)(int)(r - &menu[2]);
else if ( r > &menu[7] && r < &menu[12] )
_fade_out.type = (Fade::fade_type_e)(int)(r - &menu[8]);

redraw();
}

return 1;

}
else
return Sequence_Widget::handle( m );


Loading…
Cancel
Save