diff options
author | wlemb <wlemb> | 2004-01-05 22:49:03 +0000 |
---|---|---|
committer | wlemb <wlemb> | 2004-01-05 22:49:03 +0000 |
commit | 1943ac7c60c141af6bdc1c5dbd18d8e42daeec37 (patch) | |
tree | 89701390c5dfedff5c938d78493a462a783ea793 /src/roff/troff/node.cpp | |
parent | 263694103d242f91c4c9e1d5430aec14422d04b3 (diff) | |
download | groff-1943ac7c60c141af6bdc1c5dbd18d8e42daeec37.tar.gz |
* src/roff/troff/nroff.cpp (space_node::get_breakpoints,
space_node::nbreaks): Protect against zero `next' field.
Update copyright years.
Diffstat (limited to 'src/roff/troff/node.cpp')
-rw-r--r-- | src/roff/troff/node.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/roff/troff/node.cpp b/src/roff/troff/node.cpp index 7561259e..35f2d60c 100644 --- a/src/roff/troff/node.cpp +++ b/src/roff/troff/node.cpp @@ -3397,7 +3397,7 @@ int node::nbreaks() breakpoint *space_node::get_breakpoints(hunits width, int ns, breakpoint *rest, int is_inner) { - if (next->discardable()) + if (next && next->discardable()) return rest; breakpoint *bp = new breakpoint; bp->next = rest; @@ -3418,7 +3418,7 @@ breakpoint *space_node::get_breakpoints(hunits width, int ns, int space_node::nbreaks() { - if (next->discardable()) + if (next && next->discardable()) return 0; else return 1; |