This commit is contained in:
bluepython508 committed 2026-10-22 12:27:19 +01:00
1 parent 3530afb854
commit 6903fcff27
2146 files changed
+112256 -190703

No files matched your search

+4 -2
View File
@@ -1,4 +1,4 @@
// Copyright (c) Tailscale Inc & AUTHORS
// Copyright (c) Tailscale Inc & contributors
// SPDX-License-Identifier: BSD-3-Clause
package ipn
@@ -92,7 +92,9 @@ type StateStore interface {
// ReadState returns the bytes associated with ID. Returns (nil,
// ErrStateNotExist) if the ID doesn't have associated state.
ReadState(id StateKey) ([]byte, error)
// WriteState saves bs as the state associated with ID.
// WriteState saves bs as the state associated with ID. If bs is nil,
// the state associated with ID is deleted, and a subsequent ReadState
// for ID will return ErrStateNotExist.
//
// Callers should generally use the ipn.WriteState wrapper func
// instead, which only writes if the value is different from what's