Command to show difference between a buffer and its corresponding file
Solution 1:
diff-buffer-with-file
. I just googled for "emacs compare buffer file changed".
Solution 2:
Another option is to hit C-x s
followed by d
. This also shows a diff between a buffer and its file.
Most useful if the buffer of interest is the only one that needs saving.