shithub: neatroff

Download patch

ref: ed5601dd4cf3497c6bc63cd34fe6d78c1094594b
parent: 7c492a144688dc0e00306387bf80a654f8ea079a
author: Ali Gholami Rudi <ali@rudi.ir>
date: Mon Sep 1 15:49:05 EDT 2014

reg: modify y only if x is defined in .rn x y

--- a/reg.c
+++ b/reg.c
@@ -182,6 +182,8 @@
 
 void str_rn(int src, int dst)
 {
+	if (!sregs[src] && !sregs_dat[src])
+		return;
 	str_rm(dst);
 	sregs[dst] = sregs[src];
 	sregs_dat[dst] = sregs_dat[src];