summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Harris <pharris@opentext.com>2011-08-11 12:50:38 -0400
committerPeter Harris <pharris@opentext.com>2011-08-11 12:50:38 -0400
commitf848a900034254478adf4b57e08524a35ee386d1 (patch)
treebf1f32e3f48f617012b45b9d12523ffad55b9d2d
parent171f153c2a53ebd344a9ed9613742c2ccdefd10b (diff)
gofix for current release
-rw-r--r--xau.go12
-rw-r--r--xgob.go12
-rw-r--r--xlsclients.go2
3 files changed, 13 insertions, 13 deletions
diff --git a/xau.go b/xau.go
index 2f30f57..f42e3aa 100644
--- a/xau.go
+++ b/xau.go
@@ -8,10 +8,10 @@ import (
const (
FamilyLocal uint16 = 256 /* not part of X standard (i.e. X.h) */
- FamilyWild = 65535
- FamilyNetname = 254 /* not part of X standard */
- FamilyKrb5Principal = 253 /* Kerberos 5 principal name */
- FamilyLocalHost = 252 /* for local non-net authentication */
+ FamilyWild = 65535
+ FamilyNetname = 254 /* not part of X standard */
+ FamilyKrb5Principal = 253 /* Kerberos 5 principal name */
+ FamilyLocalHost = 252 /* for local non-net authentication */
)
type Xauth struct {
@@ -51,7 +51,7 @@ func GetAuthByAddr(family uint16, address []byte, number []byte, name string) *X
return nil
}
- auth_file, err := os.Open(auth_name, os.O_RDONLY, 0)
+ auth_file, err := os.Open(auth_name)
if err != nil {
return nil
}
@@ -95,7 +95,7 @@ func GetBestAuthByAddr(family uint16, address []byte, number []byte, types []str
return nil
}
- auth_file, err := os.Open(auth_name, os.O_RDONLY, 0)
+ auth_file, err := os.Open(auth_name)
if err != nil {
return nil
}
diff --git a/xgob.go b/xgob.go
index 36bdf9e..2cdf00b 100644
--- a/xgob.go
+++ b/xgob.go
@@ -21,10 +21,10 @@ const (
const (
FamilyInternet uint16 = 0
- FamilyDECNet = 1
- FamilyCHAOS = 2
- FamilyServerInterpreted = 5
- FamilyInternet6 = 6
+ FamilyDECNet = 1
+ FamilyCHAOS = 2
+ FamilyServerInterpreted = 5
+ FamilyInternet6 = 6
)
type Format struct {
@@ -200,7 +200,7 @@ func open_tcp(host string, protocol string, port int) io.ReadWriteCloser {
host = "localhost"
}
- conn, err := net.Dial(proto, "", host+":"+strconv.Itoa(port))
+ conn, err := net.Dial(proto, host+":"+strconv.Itoa(port))
// TODO - remove
if err != nil {
println("TCP error ", err.String())
@@ -213,7 +213,7 @@ func open_unix(protocol string, file string) io.ReadWriteCloser {
return nil
}
- conn, err := net.Dial("unix", "", file)
+ conn, err := net.Dial("unix", file)
// TODO - remove
if err != nil {
println("Unix socket error ", err.String())
diff --git a/xlsclients.go b/xlsclients.go
index b13dd48..a235de6 100644
--- a/xlsclients.go
+++ b/xlsclients.go
@@ -116,7 +116,7 @@ func quotedWords(prop []byte) string {
buf := bytes.NewBufferString("")
charsleft := *maxcmdlen
- words := bytes.Split(prop, []byte{0}, -1)
+ words := bytes.Split(prop, []byte{0})
for i, word := range words {
charsleft -= quotedWord(buf, word, charsleft)
if i < len(words)-1 {