]> Cypherpunks.ru repositories - nncp.git/blobdiff - src/cypherpunks.ru/nncp/jobs.go
SeekStart constant instead of hardcode
[nncp.git] / src / cypherpunks.ru / nncp / jobs.go
index 1f3afd1e4f93534347b1826b73e28a62c48c16e1..2bbde622895d3469b0adc51b3027fc38c21377ac 100644 (file)
@@ -19,6 +19,7 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 package nncp
 
 import (
+       "io"
        "os"
        "path/filepath"
        "strconv"
@@ -68,7 +69,7 @@ func (ctx *Ctx) Jobs(nodeId *NodeId, xx TRxTx) chan Job {
                                fd.Close()
                                continue
                        }
-                       fd.Seek(0, 0)
+                       fd.Seek(0, io.SeekStart)
                        ctx.LogD("jobs", SDS{
                                "xx":   string(xx),
                                "node": pktEnc.Sender,