Al-HUWAITI Shell
Al-huwaiti


Server : LiteSpeed
System : Linux in-mum-web1333.main-hosting.eu 4.18.0-553.37.1.lve.el8.x86_64 #1 SMP Mon Feb 10 22:45:17 UTC 2025 x86_64
User : u141265441 ( 141265441)
PHP Version : 8.4.3
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
Directory :  /proc/self/root/opt/golang/1.22.0/src/cmd/go/testdata/script/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/self/root/opt/golang/1.22.0/src/cmd/go/testdata/script/test_fuzz_dup_cache.txt
[!fuzz] skip
[short] skip
env GOCACHE=$WORK/cache

# This test checks that cached corpus loading properly handles duplicate entries (this can
# happen when a f.Add value has a duplicate entry in the cached corpus.) Duplicate entries
# should be discarded, and the rest of the cache should be loaded as normal.

env GOCACHE=$WORK/cache
env GODEBUG=fuzzdebug=1

mkdir -p $GOCACHE/fuzz/fuzztest/FuzzTarget
go run ./populate $GOCACHE/fuzz/fuzztest/FuzzTarget

go test -fuzz=FuzzTarget -fuzztime=10x .
stdout 'entries: 5'

-- go.mod --
module fuzztest

go 1.17

-- fuzz_test.go --
package fuzz

import "testing"

func FuzzTarget(f *testing.F) {
    f.Add(int(0))
    f.Fuzz(func(t *testing.T, _ int) {})
}

-- populate/main.go --
package main

import (
    "path/filepath"
	"fmt"
	"os"
)

func main() {
	for i := 0; i < 10; i++ {
		b := byte(0)
		if i > 5 {
			b = byte(i)
		}
        tmpl := "go test fuzz v1\nint(%d)\n"
		if err := os.WriteFile(filepath.Join(os.Args[1], fmt.Sprint(i)), []byte(fmt.Sprintf(tmpl, b)), 0777); err != nil {
			panic(err)
		}
	}
}

Al-HUWAITI Shell