diff options
author | Thomas White <taw@bitwiz.org.uk> | 2018-03-07 13:01:39 +0100 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2018-03-07 13:01:39 +0100 |
commit | 74ad51de1a6dc74b9c253c254cccfe543d0c69b0 (patch) | |
tree | a7ff73a01bc40e1e570dcc8d97edb6258ca43ded /src/frame.c | |
parent | 8fb0c2bd7c8308914f8ad2cd052bf247e47efec5 (diff) |
Formatting
Diffstat (limited to 'src/frame.c')
-rw-r--r-- | src/frame.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/frame.c b/src/frame.c index af95767..151a545 100644 --- a/src/frame.c +++ b/src/frame.c @@ -1495,13 +1495,13 @@ void delete_text_from_frame(struct frame *fr, struct edit_pos p1, struct edit_po break; } printf("name is '%s'\n", sc_block_name(scblock)); + if ( (sc_block_name(scblock) != NULL) && (strcmp(sc_block_name(scblock), "newpara") == 0) ) { /* Deleting newpara block, merge the paragraphs */ merge_paragraphs_by_newpara(fr, scblock); p2.para--; - } next = sc_block_next(scblock); @@ -1530,7 +1530,8 @@ void delete_text_from_frame(struct frame *fr, struct edit_pos p1, struct edit_po printf("deleting block %p\n", p2scblock); show_sc_block(p2scblock, ""); sc_block_delete(&fr->scblocks, p2scblock); - delete_run_for_scblock(fr, fr->paras[p1.para], fr->paras[p2.para], p2scblock); + delete_run_for_scblock(fr, fr->paras[p1.para], + fr->paras[p2.para], p2scblock); } else if ( p2offs > 0 ) { printf("Partial delete\n"); printf("contents '%s'\n", sc_block_contents(p2rscblock)); |