File tree 5 files changed +6
-3
lines changed
5 files changed +6
-3
lines changed Original file line number Diff line number Diff line change 1
1
2021-06-05 (12.22)
2
2
COMMON: Fixes 'Socket Client doesn't receive byte with value 13' #112
3
+ COMMON: Fixes TSAVE of arrays includes extra null character. #119
3
4
4
5
2021-05-03 (12.22)
5
6
COMMON: Fix array access regression
Original file line number Diff line number Diff line change @@ -530,7 +530,7 @@ void cmd_print(int output) {
530
530
if (code_peek () == kwTYPE_EOC || code_peek () == kwTYPE_LINE ) {
531
531
// There are no parameters
532
532
if (dev_fstatus (handle )) {
533
- dev_fwrite (handle , (byte * )OS_LINESEPARATOR , sizeof ( OS_LINESEPARATOR ) );
533
+ dev_fwrite (handle , (byte * )OS_LINESEPARATOR , OS_LINESEPARATOR_LEN );
534
534
} else {
535
535
err_fopen ();
536
536
}
Original file line number Diff line number Diff line change @@ -725,7 +725,7 @@ void cmd_fsaveln() {
725
725
for (int i = 0 ; i < v_asize (array_p ); i ++ ) {
726
726
var_p = v_elem (array_p , i );
727
727
fprint_var (handle , var_p );
728
- dev_fwrite (handle , (byte * )OS_LINESEPARATOR , sizeof ( OS_LINESEPARATOR ) );
728
+ dev_fwrite (handle , (byte * )OS_LINESEPARATOR , OS_LINESEPARATOR_LEN );
729
729
}
730
730
} else {
731
731
// parameter is an string
Original file line number Diff line number Diff line change @@ -25,7 +25,6 @@ bcip_t comp_search_bc(bcip_t ip, code_t code);
25
25
bcip_t comp_next_bc_cmd (bc_t * bc , bcip_t ip );
26
26
extern void expr_parser (bc_t * bc );
27
27
28
- #define STRLEN (s ) ((sizeof(s) / sizeof(s[0])) - 1)
29
28
const int LEN_OPTION = STRLEN (LCN_OPTION );
30
29
const int LEN_IMPORT = STRLEN (LCN_IMPORT_WRS );
31
30
const int LEN_UNIT = STRLEN (LCN_UNIT_WRS );
Original file line number Diff line number Diff line change @@ -60,6 +60,9 @@ extern "C" {
60
60
#define OS_LINESEPARATOR "\n"
61
61
#endif
62
62
63
+ #define STRLEN (s ) ((sizeof(s) / sizeof(s[0])) - 1)
64
+ #define OS_LINESEPARATOR_LEN STRLEN(OS_LINESEPARATOR)
65
+
63
66
#if UINTPTR_MAX == 0xffffffff
64
67
#define SB_BIT_SZ "_32 "
65
68
#else
You can’t perform that action at this time.
0 commit comments