Disable LoadExtension when omit_load_extension is specified

This commit is contained in:
Zbigniew Mandziejewicz 2016-04-18 19:58:56 +08:00
parent da9decb965
commit 4bc448f79b
2 changed files with 5 additions and 1 deletions

View File

@ -8,6 +8,6 @@ package sqlite3
/* /*
#cgo CFLAGS: -DUSE_LIBSQLITE3 #cgo CFLAGS: -DUSE_LIBSQLITE3
#cgo LDFLAGS: -lsqlite3 #cgo linux darwin LDFLAGS: -lsqlite3
*/ */
import "C" import "C"

View File

@ -17,3 +17,7 @@ import (
func (c *SQLiteConn) loadExtensions(extensions []string) error { func (c *SQLiteConn) loadExtensions(extensions []string) error {
return errors.New("Extensions have been disabled for static builds") return errors.New("Extensions have been disabled for static builds")
} }
func (c *SQLiteConn) LoadExtension(lib string, entry string) error {
return errors.New("Extensions have been disabled for static builds")
}