This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[gccgo] libgo RTEMS fix


This patch from Vinu Rajashekhar fixes the RTEMS code by using
assignment rather than a new variable declaration.  Committed to gccgo
branch.

Ian

Index: libgo/go/net/fd_rtems.go
===================================================================
--- libgo/go/net/fd_rtems.go	(revision 162069)
+++ libgo/go/net/fd_rtems.go	(working copy)
@@ -112,11 +112,11 @@ func (p *pollster) WaitFD(nsec int64) (f
 	for i := p.lastFd; i < p.maxFd + 1; i++ {
 		if syscall.FDIsSet(i, p.readyReadFds) {
 			flag = true
-			mode := 'r'
+			mode = 'r'
 			syscall.FDClr(i, p.readyReadFds)
 		} else if syscall.FDIsSet(i, p.readyWriteFds) {
 			flag = true
-			mode := 'w'
+			mode = 'w'
 			syscall.FDClr(i, p.readyWriteFds)
 		}
 		if flag {

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]