view move-if-change @ 112267:bee0a8fef127

Avoid crash in Fselect_frame due to null selected_window (Bug#7728). * window.c (inhibit_point_swap): New variable. (Fselect_window): If inhibit_point_swap is nonzero, avoid swapping point this time. (Fset_window_configuration): Set inhibit_point_swap to 1 instead of setting selected_window to nil (Bug#7728).
author Chong Yidong <cyd@stupidchicken.com>
date Fri, 14 Jan 2011 21:55:58 -0500
parents 354e0c45cedf
children 14a97ab281d5
line wrap: on
line source

#!/bin/sh
if
test -r $2
then
if
cmp $1 $2 > /dev/null
then
echo $2 is unchanged
rm -f $1
else
mv -f $1 $2
fi
else
mv -f $1 $2
fi