Index: arch/mips/src/exception.c
===================================================================
--- arch/mips/src/exception.c	(revision f761f1eb635bfe9a5deaf70a0f0a51aa8d2f5f22)
+++ arch/mips/src/exception.c	(revision 7b7d7d1cbbddea9be6f0e75c0adabf7bda19ad53)
@@ -43,7 +43,7 @@
 	cp0_status_write(cp0_status_read() & ~ cp0_status_exl_exception_bit);
 
-	if (the->thread) {
-		the->thread->saved_pri = pri;
-		the->thread->saved_epc = epc;
+	if (THREAD) {
+		THREAD->saved_pri = pri;
+		THREAD->saved_epc = epc;
 	}
 	/* decode exception number and process the exception */
@@ -55,7 +55,7 @@
 	}
 	
-	if (the->thread) {
-		pri = the->thread->saved_pri;
-		epc = the->thread->saved_epc;
+	if (THREAD) {
+		pri = THREAD->saved_pri;
+		epc = THREAD->saved_epc;
 	}
 
