diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/client_integration_test.go golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/client_integration_test.go --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/client_integration_test.go 2016-01-15 09:48:22.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/client_integration_test.go 2016-01-29 01:04:45.000000000 +0000 @@ -102,7 +102,6 @@ server, err := NewServer( txPipeRd, rxPipeWr, - ".", options..., ) if err != nil { diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/debian/changelog golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/debian/changelog --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/debian/changelog 2016-01-15 10:29:52.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/debian/changelog 2016-01-29 01:08:48.000000000 +0000 @@ -1,3 +1,10 @@ +golang-github-pkg-sftp (0.0~git20160118.0.e84cc8c-1) unstable; urgency=medium + + * New upstream snapshot + * Remove unnecessary Depends on golang-go | gccgo + + -- Anthony Fok Fri, 29 Jan 2016 09:08:37 +0800 + golang-github-pkg-sftp (0.0~git20160111.0.8a7343c-1) unstable; urgency=medium * Initial release (Closes: #811062) diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/debian/control golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/debian/control --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/debian/control 2016-01-15 10:28:49.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/debian/control 2016-01-29 01:07:46.000000000 +0000 @@ -18,7 +18,6 @@ Architecture: all Depends: ${shlibs:Depends}, ${misc:Depends}, - golang-go | gccgo, golang-github-kr-fs-dev, golang-golang-x-crypto-dev Description: SFTP support for the golang.org/x/crypto/ssh package diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/examples/sftp-server/main.go golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/examples/sftp-server/main.go --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/examples/sftp-server/main.go 2016-01-15 09:48:22.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/examples/sftp-server/main.go 2016-01-29 01:04:45.000000000 +0000 @@ -21,12 +21,10 @@ var ( readOnly bool debugStderr bool - rootDir string ) flag.BoolVar(&readOnly, "R", false, "read-only server") flag.BoolVar(&debugStderr, "e", false, "debug to stderr") - flag.StringVar(&rootDir, "root", "", "root directory") flag.Parse() debugStream := ioutil.Discard @@ -123,7 +121,6 @@ server, err := sftp.NewServer( channel, channel, - rootDir, sftp.WithDebug(debugStream), sftp.ReadOnly(), ) diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/server.go golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/server.go --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/server.go 2016-01-15 09:48:22.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/server.go 2016-01-29 01:04:45.000000000 +0000 @@ -29,7 +29,6 @@ outMutex *sync.Mutex debugStream io.Writer readOnly bool - rootDir string lastID uint32 pktChan chan rxPacket openFiles map[string]*os.File @@ -74,26 +73,16 @@ } // NewServer creates a new Server instance around the provided streams, serving -// content from the directory specified by rootDir. Optionally, ServerOption +// content from the root of the filesystem. Optionally, ServerOption // functions may be specified to further configure the Server. // // A subsequent call to Serve() is required to begin serving files over SFTP. -func NewServer(in io.Reader, out io.WriteCloser, rootDir string, options ...ServerOption) (*Server, error) { - if rootDir == "" { - wd, err := os.Getwd() - if err != nil { - return nil, err - } - - rootDir = wd - } - +func NewServer(in io.Reader, out io.WriteCloser, options ...ServerOption) (*Server, error) { s := &Server{ in: in, out: out, outMutex: &sync.Mutex{}, debugStream: ioutil.Discard, - rootDir: rootDir, pktChan: make(chan rxPacket, sftpServerWorkerCount), openFiles: map[string]*os.File{}, openFilesLock: &sync.RWMutex{}, diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/server_integration_test.go golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/server_integration_test.go --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/server_integration_test.go 2016-01-15 09:48:22.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/server_integration_test.go 2016-01-29 01:04:45.000000000 +0000 @@ -297,7 +297,6 @@ sftpServer, err := NewServer( chsvr.ch, chsvr.ch, - ".", WithDebug(sftpServerDebugStream), ) if err != nil { diff -Nru golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/server_standalone/main.go golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/server_standalone/main.go --- golang-github-pkg-sftp-0.0~git20160111.0.8a7343c/server_standalone/main.go 2016-01-15 09:48:22.000000000 +0000 +++ golang-github-pkg-sftp-0.0~git20160118.0.e84cc8c/server_standalone/main.go 2016-01-29 01:04:45.000000000 +0000 @@ -30,7 +30,6 @@ svr, _ := sftp.NewServer( os.Stdin, os.Stdout, - "", sftp.WithDebug(debugStream), sftp.ReadOnly(), )