// CancelReset allows a user to cancel the reset process via an authenticated API call.
975074
func (h *AccountHandler) CancelReset(ctx context.Context, sessionID int) error {
	mctx := libkb.NewMetaContext(ctx, h.G())
	return libkb.CancelResetPipeline(mctx)
}
375842
func (c *cancel) Cancel(id jsonrpc2.ID) {
	var cancel func()
	c.mu.Lock()
	if c.m != nil {
		cancel = c.m[id]
		delete(c.m, id)
	}
	c.mu.Unlock()
	if cancel != nil {
		cancel()
	}
}
649869
func (c *CompletionManager) Reset() {
	c.selected = -1
	c.verticalScroll = 0
	c.Update(*NewDocument())
	return
}
293230
func (db *DB) Reset() error {
	var err error
	exec := func(sql string) {
		if err == nil {
			err = db.Exec(sql).Error
		}
	}

	exec(`TRUNCATE TABLE apps CASCADE`)
	exec(`TRUNCATE TABLE ports CASCADE`)
	exec(`TRUNCATE TABLE slugs CASCADE`)
	exec(`UPDATE ports SET app_id = NULL`)

	return err
}
175010
func (m *MockStream) CancelRead(arg0 protocol.ApplicationErrorCode) {
	m.ctrl.T.Helper()
	m.ctrl.Call(m, "CancelRead", arg0)
}
1256824
func (c *OperatorGenerateRootCommand) cancel(client *api.Client, drToken bool) int {
	f := client.Sys().GenerateRootCancel
	if drToken {
		f = client.Sys().GenerateDROperationTokenCancel
	}
	if err := f(); err != nil {
		c.UI.Error(fmt.Sprintf("Error canceling root token generation: %s", err))
		return 2
	}
	c.UI.Output("Success! Root token generation canceled (if it was started)")
	return 0
}
563455
func Reset() {
	var d net.Dialer
	OverrideDial(d.DialContext)
	OverrideResolve(net.ResolveTCPAddr)
	OverrideListenUDP(func(network string, laddr *net.UDPAddr) (net.PacketConn, error) {
		return net.ListenUDP(network, laddr)
	})
	OverrideDialUDP(func(network string, laddr, raddr *net.UDPAddr) (net.PacketConn, error) {
		return net.DialUDP(network, laddr, raddr)
	})
}
1125290
func (a *AccountState) Reset(mctx libkb.MetaContext) {
	a.Lock()
	defer a.Unlock()

	a.refreshReqs = nil
	a.done = true
}
717850
func (this *HttpClient) reset() {
	this.oneTimeOptions = nil
	this.oneTimeHeaders = nil
	this.oneTimeCookies = nil
	this.reuseTransport = true
	this.reuseJar = true

	// nil means the Begin has not been called, asume requests are not
	// concurrent.
	if this.withLock {
		this.lock.Unlock()
	}
}
1116196
func Cancel(id string, params *stripe.PaymentIntentCancelParams) (*stripe.PaymentIntent, error) {
	return getC().Cancel(id, params)
}
249062
func (this *Future) Cancel() (e error) {
	return this.setResult(&PromiseResult{CANCELLED, RESULT_CANCELLED})
}
316693
func (a *DictAcceptor) Reset(p int) {
	a.p = p
	a.final = false
	a.offset = 0
	a.valid = true
}
213848
func (o *option) Reset() {
	o.isLong = false
	o.count = 0
	o.value.Set(o.defval, o)
}
157116
func (t *transport) CancelRequest(req *http.Request) {
	type canceler interface {
		CancelRequest(*http.Request)
	}
	if cr, ok := t.base().(canceler); ok {
		t.mu.Lock()
		modReq := t.modReq[req]
		delete(t.modReq, req)
		t.mu.Unlock()
		cr.CancelRequest(modReq)
	}
}
64364
func resetReplicaSet(dialInfo *mgo.DialInfo, memberHostPort string) error {
	params := peergrouper.InitiateMongoParams{
		DialInfo:       dialInfo,
		MemberHostPort: memberHostPort,
		User:           dialInfo.Username,
		Password:       dialInfo.Password,
	}
	return peergrouper.InitiateMongoServer(params)
}
1077111
func (s *SimpleFSHandler) SimpleFSReset(
	ctx context.Context, path keybase1.Path) (err error) {
	ctx, cancel := s.wrapContextWithTimeout(ctx)
	defer cancel()
	cli, err := s.client()
	if err != nil {
		return err
	}
	return cli.SimpleFSReset(ctx, path)
}
820456
func (pool *TxPool) lockedReset(oldHead, newHead *types.Header) {
	pool.mu.Lock()
	defer pool.mu.Unlock()

	pool.reset(oldHead, newHead)
}