Opened 10 years ago

Closed 10 years ago

#615 closed defect (fixed)

Search Files tool crashes when used twice in a row

Reported by: gfoy Owned by:
Priority: normal Milestone: Clozure CL 1.4
Component: IDE Version: trunk
Keywords: Cc:

Description

There was an obvious array reference error in #/updateResults: which the code below fixes. The call to expand-all-results also occasionally caused an error (??), so I've commented it out.

This is not the same problem as ticket #456

From ccl/cocoa-ide/search-files.lisp

(objc:defMethod (#/updateResults: :void) ((wc search-files-window-controller)

msg)

(let* ((old-results (search-results wc)))

(setf (search-results wc) (new-results wc)) ;; release NSString instances. sigh. (dotimes (idx (length old-results))

(let* ((file (aref old-results idx))

(lines (when file (search-result-file-lines file))))

(dotimes (idx (length lines))

(let* ((line (aref lines idx))

(string (when line (search-result-line-nsstr line))))

(and string (#/release string))))

(and (search-result-file-nsstr file)

(#/release (search-result-file-nsstr file)))))

(set-results-string wc msg)

; (when (or (auto-expandable-p (search-results wc)) ; (expand-results-p wc)) ; (expand-all-results wc))

(#/reloadData (outline-view wc)) (#/setEnabled: (search-button wc) t)))

Change History (1)

comment:1 Changed 10 years ago by rme

  • Resolution set to fixed
  • Status changed from new to closed

(In [13116]) Patch to #/updateResults: from gfoy. (fixes ticket:615)

Note: See TracTickets for help on using tickets.