1
0
Fork 0
forked from External/grumble

grumble, pkg/*: go fmt.

This commit is contained in:
Mikkel Krautz 2012-11-18 17:59:07 +01:00
parent d77f8843a7
commit dd76f22eb7
14 changed files with 62 additions and 61 deletions

View file

@ -17,13 +17,13 @@ import (
)
type BlobStore struct {
dir string
dir string
}
var (
ErrBadFile = errors.New("a bad file exists in the blobstore directory. unable to create container directores.")
ErrNoSuchKey = errors.New("no such key")
ErrInvalidKey = errors.New("invalid key")
ErrBadFile = errors.New("a bad file exists in the blobstore directory. unable to create container directores.")
ErrNoSuchKey = errors.New("no such key")
ErrInvalidKey = errors.New("invalid key")
)
var (
@ -143,7 +143,7 @@ func NewBlobStore(path string) (bs *BlobStore, err error) {
}
bs = &BlobStore{
dir: path,
dir: path,
}
return bs, nil
}
@ -281,4 +281,4 @@ func (bs *BlobStore) Put(buf []byte) (key string, err error) {
}
return key, nil
}
}

View file

@ -32,7 +32,7 @@ type CryptState struct {
RemoteLost uint32
RemoteResync uint32
cipher cipher.Block
cipher cipher.Block
}
func New() (cs *CryptState, err error) {

View file

@ -5,8 +5,8 @@
package freezer
import (
"encoding/binary"
"code.google.com/p/goprotobuf/proto"
"encoding/binary"
"hash"
"hash/crc32"
"io"

View file

@ -1,9 +1,9 @@
package packetdatastream
import (
"testing"
"math"
"crypto/rand"
"math"
"testing"
)
func TestSelfUint8(t *testing.T) {

View file

@ -1,6 +1,6 @@
// Copyright (c) 2012 The Grumble Authors
// The use of this source code is goverened by a BSD-style
// license that can be found in the LICENSE-file.
// Package replacefile implements access to the ReplaceFile Win32 API.
package replacefile
// Copyright (c) 2012 The Grumble Authors
// The use of this source code is goverened by a BSD-style
// license that can be found in the LICENSE-file.
// Package replacefile implements access to the ReplaceFile Win32 API.
package replacefile

View file

@ -1,12 +1,12 @@
// Copyright (c) 2012 The Grumble Authors
// The use of this source code is goverened by a BSD-style
// license that can be found in the LICENSE-file.
package replacefile
type Flag uint32
const (
IgnoreMergeErrors Flag = 0x2
IgnoreACLErrors Flag = 0x4
)
// Copyright (c) 2012 The Grumble Authors
// The use of this source code is goverened by a BSD-style
// license that can be found in the LICENSE-file.
package replacefile
type Flag uint32
const (
IgnoreMergeErrors Flag = 0x2
IgnoreACLErrors Flag = 0x4
)

View file

@ -1,22 +1,22 @@
// Copyright (c) 2012 The Grumble Authors
// The use of this source code is goverened by a BSD-style
// license that can be found in the LICENSE-file.
// +build !windows
package replacefile
import (
"errors"
)
var (
errOnlyWindows = errors.New("replacefile: only implemented on Windows")
ErrUnableToMoveReplacement error = errOnlyWindows
ErrUnableToMoveReplacement2 error = errOnlyOnWindows
ErrUnableToRemoveReplaced error = errOnlyWindows
)
func ReplaceFile(replaced string, replacement string, backup string, flags Flag) error {
return errOnlyWindows
}
// Copyright (c) 2012 The Grumble Authors
// The use of this source code is goverened by a BSD-style
// license that can be found in the LICENSE-file.
// +build !windows
package replacefile
import (
"errors"
)
var (
errOnlyWindows = errors.New("replacefile: only implemented on Windows")
ErrUnableToMoveReplacement error = errOnlyWindows
ErrUnableToMoveReplacement2 error = errOnlyOnWindows
ErrUnableToRemoveReplaced error = errOnlyWindows
)
func ReplaceFile(replaced string, replacement string, backup string, flags Flag) error {
return errOnlyWindows
}