VM

set-buffer-multibyte problems (from Bug #495089)

Bug #498623 reported by Uday Reddy
4
This bug affects 1 person
Affects Status Importance Assigned to Milestone
VM
Triaged
Medium
Ulrich Müller

Bug Description

This is left over from Bug #495089
The problem here was caused by the call to set-buffer-multibyte, which is a questionable function. There are 13 remaining calls to this function in the current version. I will keep this bug report alive until I have looked at all the 13.

Uday Reddy (reddyuday)
Changed in vm:
status: New → Triaged
importance: Undecided → Medium
assignee: nobody → Uday Reddy (reddyuday)
Uday Reddy (reddyuday)
Changed in vm:
assignee: Uday Reddy (reddyuday) → nobody
Revision history for this message
Uday Reddy (reddyuday) wrote :

Ulrich, can you take a lead on this please? I can look at any instances that you flag up for me. -- Uday

Changed in vm:
assignee: nobody → Ulrich Müller (ulm)
milestone: none → 8.2.0-devo
Revision history for this message
Ulrich Müller (ulm) wrote :

I believe that the following calls are o.k., since they are either done for an empty buffer, or immediately followed by a call to erase-buffer:
   vm-edit.el:73: (set-buffer-multibyte nil))
   vm-mime.el:2733: (set-buffer-multibyte nil))
   vm-mime.el:3112: (set-buffer-multibyte nil))
   vm-mime.el:5237: (set-buffer-multibyte nil))
   vm-pine.el:1154: (set-buffer-multibyte nil))
   vm-window.el:126: (set-buffer-multibyte nil))
   vm-window.el:145: (set-buffer-multibyte nil))

The following is redundant and should be removed (vm-make-work-buffer is guaranteed to create a single-byte buffer):
   vm-mime.el:4609: (set-buffer-multibyte nil))

Still to be checked:
   vm.el:134: (set-buffer-multibyte nil))
   vm-mime.el:321: (and vm-fsfemacs-p (set-buffer-multibyte t))
   vm-mime.el:1956: (and vm-fsfemacs-mule-p (set-buffer-multibyte t))
   vm-reply.el:980: (set-buffer-multibyte t)))
   vm-save.el:65: (set-buffer-multibyte nil))

Uday Reddy (reddyuday)
Changed in vm:
milestone: 8.2.0-devo → 8.1.2
Revision history for this message
Ulrich Müller (ulm) wrote :

Status update:

I've removed the following call to set-buffer-multibyte in the 8.1.x branch:
   vm-mime.el:4609: (set-buffer-multibyte nil))

This call is o.k., it is followed by erase-buffer:
   vm-save.el:65: (set-buffer-multibyte nil))

Leaves us with the following four, line numbers are for revision 746 in the 8.1.x branch:
   vm.el:139: (set-buffer-multibyte nil))
   vm-mime.el:321: (and vm-fsfemacs-p (set-buffer-multibyte t))
   vm-mime.el:1948: (and vm-fsfemacs-mule-p (set-buffer-multibyte t))
   vm-reply.el:981: (set-buffer-multibyte t)))

Uday Reddy (reddyuday)
Changed in vm:
milestone: 8.1.2 → 8.2.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.