You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: message.go
    path of file: ./repos/emitter/internal/message
    
    the code of the file until where you have to start completion: /**********************************************************************************
* Copyright (c) 2009-2019 Misakai Ltd.
* This program is free software: you can redistribute it and/or modify it under the
* terms of the GNU Affero General Public License as published by the  Free Software

    
func DecodeFrame(buf []byte) (out Frame, err error) {

	// We need to allocate, given that the unmarshal is now no-copy. By using 'nil' as destination
	// we make sure that the underlying buffer is calculated based on the decoded length.
	if buf, err = snappy.Decode(nil, buf); err == nil {
		err = binary.Unmarshal(buf, &out)
	}
	return
}