]> git.eshelyaron.com Git - emacs.git/commitdiff
(try_window_id): Don't call set_cursor_from_row if
authorKim F. Storm <storm@cua.dk>
Wed, 11 Dec 2002 21:21:17 +0000 (21:21 +0000)
committerKim F. Storm <storm@cua.dk>
Wed, 11 Dec 2002 21:21:17 +0000 (21:21 +0000)
row_containing_pos returned NULL.

src/xdisp.c

index bfe9d4f96376a98eb8c7cc61531bc5161d46fa60..aff2421a1b72153a773ce141e5f89ea256a270fd 100644 (file)
@@ -11732,7 +11732,8 @@ try_window_id (w)
 
          /* Set the cursor.  */
          row = row_containing_pos (w, PT, r0, NULL, 0);
-         set_cursor_from_row (w, row, current_matrix, 0, 0, 0, 0);
+         if (row)
+           set_cursor_from_row (w, row, current_matrix, 0, 0, 0, 0);
          return 1;
        }
     }
@@ -11770,7 +11771,8 @@ try_window_id (w)
 
          /* Set the cursor.  */
          row = row_containing_pos (w, PT, r0, NULL, 0);
-         set_cursor_from_row (w, row, current_matrix, 0, 0, 0, 0);
+         if (row)
+           set_cursor_from_row (w, row, current_matrix, 0, 0, 0, 0);
          return 2;
        }
     }