mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-24 20:45:06 +02:00
Fix crash when cdr is a value type
This commit is contained in:
parent
d77b94d89c
commit
730fdb3111
1 changed files with 1 additions and 1 deletions
|
@ -789,7 +789,7 @@ static object _Cyc_write(object x, FILE * port)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (tmp = cdr(x); tmp && ((closure) tmp)->tag == pair_tag; tmp = cdr(tmp)) {
|
for (tmp = cdr(x); tmp && !is_value_type(tmp) && ((closure) tmp)->tag == pair_tag; tmp = cdr(tmp)) {
|
||||||
if (has_cycle == boolean_t) {
|
if (has_cycle == boolean_t) {
|
||||||
if (i++ > 20)
|
if (i++ > 20)
|
||||||
break; /* arbitrary number, for now */
|
break; /* arbitrary number, for now */
|
||||||
|
|
Loading…
Add table
Reference in a new issue