Cannot use as value this one has me

When go run I get the following error.
.\copyres.go:76:50: syntax error: cannot use destsize := destinationstat.Size() as value
I know this is annoying. I can usually see it and work it out. But this time I can’t see it.
Here is a snippet.
destinationstat, err := os.Stat(tofile)
if err == null
destsize := destinationstat.Size()
if destsize != nosize {
retry = false
}
}
Any help appreciated. I’m sure it’s small. As I said, I can’t see it and it is driving me crazy.

Hi @chrisleahy, there is a curly brace missing in this line. Is it missing in the original code, too? This might have caused the error message.

Thank you. Too many late nights I think to have missed that.