浏览代码

[MIPS] Compliment va_start() with va_end().

Signed-off-by: Richard Knutsson <ricknu-0@student.ltu.se>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Richard Knutsson 17 年之前
父节点
当前提交
8142294dda
共有 3 个文件被更改,包括 6 次插入0 次删除
  1. 2 0
      arch/mips/math-emu/ieee754.c
  2. 2 0
      arch/mips/math-emu/ieee754dp.c
  3. 2 0
      arch/mips/math-emu/ieee754sp.c

+ 2 - 0
arch/mips/math-emu/ieee754.c

@@ -108,6 +108,7 @@ int ieee754si_xcpt(int r, const char *op, ...)
 	ax.rv.si = r;
 	ax.rv.si = r;
 	va_start(ax.ap, op);
 	va_start(ax.ap, op);
 	ieee754_xcpt(&ax);
 	ieee754_xcpt(&ax);
+	va_end(ax.ap);
 	return ax.rv.si;
 	return ax.rv.si;
 }
 }
 
 
@@ -122,5 +123,6 @@ s64 ieee754di_xcpt(s64 r, const char *op, ...)
 	ax.rv.di = r;
 	ax.rv.di = r;
 	va_start(ax.ap, op);
 	va_start(ax.ap, op);
 	ieee754_xcpt(&ax);
 	ieee754_xcpt(&ax);
+	va_end(ax.ap);
 	return ax.rv.di;
 	return ax.rv.di;
 }
 }

+ 2 - 0
arch/mips/math-emu/ieee754dp.c

@@ -57,6 +57,7 @@ ieee754dp ieee754dp_xcpt(ieee754dp r, const char *op, ...)
 	ax.rv.dp = r;
 	ax.rv.dp = r;
 	va_start(ax.ap, op);
 	va_start(ax.ap, op);
 	ieee754_xcpt(&ax);
 	ieee754_xcpt(&ax);
+	va_end(ax.ap);
 	return ax.rv.dp;
 	return ax.rv.dp;
 }
 }
 
 
@@ -83,6 +84,7 @@ ieee754dp ieee754dp_nanxcpt(ieee754dp r, const char *op, ...)
 	ax.rv.dp = r;
 	ax.rv.dp = r;
 	va_start(ax.ap, op);
 	va_start(ax.ap, op);
 	ieee754_xcpt(&ax);
 	ieee754_xcpt(&ax);
+	va_end(ax.ap);
 	return ax.rv.dp;
 	return ax.rv.dp;
 }
 }
 
 

+ 2 - 0
arch/mips/math-emu/ieee754sp.c

@@ -58,6 +58,7 @@ ieee754sp ieee754sp_xcpt(ieee754sp r, const char *op, ...)
 	ax.rv.sp = r;
 	ax.rv.sp = r;
 	va_start(ax.ap, op);
 	va_start(ax.ap, op);
 	ieee754_xcpt(&ax);
 	ieee754_xcpt(&ax);
+	va_end(ax.ap);
 	return ax.rv.sp;
 	return ax.rv.sp;
 }
 }
 
 
@@ -84,6 +85,7 @@ ieee754sp ieee754sp_nanxcpt(ieee754sp r, const char *op, ...)
 	ax.rv.sp = r;
 	ax.rv.sp = r;
 	va_start(ax.ap, op);
 	va_start(ax.ap, op);
 	ieee754_xcpt(&ax);
 	ieee754_xcpt(&ax);
+	va_end(ax.ap);
 	return ax.rv.sp;
 	return ax.rv.sp;
 }
 }