-
Notifications
You must be signed in to change notification settings - Fork 279
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes of note: * Add instructions on README * Switch from using 'var _ = _go_fuz_dep_.Main' to 'var _ = _go_fuz_dep_.CoverTab' to avoid "imported but not used" errors in instrumented code. This is because CoverTab is always present, but libFuzzer code doesn't need Main. * Switch from a format string to text/template to generate the main package. * Rework the 'go build' command at the core of buildInstrumentedBinary. Passing an empty "extraBuildFlags" to go build does not work: go build interprets the empty string as a package name. Also, don't bother renaming outf; it gets renamed (for libfuzzer) or read and deleted (for go-fuzz) later. * Extract shared code from go-fuzz-dep main.go/main_libFuzzer.go, so that the only code in each is truly specific to that target.
- Loading branch information
Showing
7 changed files
with
81 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// Copyright 2019 go-fuzz project authors. All rights reserved. | ||
// Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. | ||
|
||
// +build gofuzz | ||
|
||
package gofuzzdep | ||
|
||
import ( | ||
. "github.com/dvyukov/go-fuzz/go-fuzz-defs" | ||
) | ||
|
||
// Bool is just a bool. | ||
// It is used by code autogenerated by go-fuzz-build | ||
// to avoid compilation errors when a user's code shadows the built-in bool. | ||
type Bool = bool | ||
|
||
var CoverTab *[CoverSize]byte |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters