Skip to content

Commit 81af0c8

Browse files
committed
Spelling, grammar, and link fixes
1 parent 19171b5 commit 81af0c8

File tree

7 files changed

+17
-17
lines changed

7 files changed

+17
-17
lines changed

CHANGELOG.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ New Features:
162162

163163
- Enable microsecond resolution on TIME, DATETIME and TIMESTAMP (#249)
164164
- Support for returning table alias on Columns() (#289, #359, #382)
165-
- Placeholder interpolation, can be actived with the DSN parameter `interpolateParams=true` (#309, #318, #490)
165+
- Placeholder interpolation, can be activated with the DSN parameter `interpolateParams=true` (#309, #318, #490)
166166
- Support for uint64 parameters with high bit set (#332, #345)
167167
- Cleartext authentication plugin support (#327)
168168
- Exported ParseDSN function and the Config struct (#403, #419, #429)
@@ -206,7 +206,7 @@ Changes:
206206
- Also exported the MySQLWarning type
207207
- mysqlConn.Close returns the first error encountered instead of ignoring all errors
208208
- writePacket() automatically writes the packet size to the header
209-
- readPacket() uses an iterative approach instead of the recursive approach to merge splitted packets
209+
- readPacket() uses an iterative approach instead of the recursive approach to merge split packets
210210

211211
New Features:
212212

@@ -254,7 +254,7 @@ Bugfixes:
254254

255255
- Fixed MySQL 4.1 support: MySQL 4.1 sends packets with lengths which differ from the specification
256256
- Convert to DB timezone when inserting `time.Time`
257-
- Splitted packets (more than 16MB) are now merged correctly
257+
- Split packets (more than 16MB) are now merged correctly
258258
- Fixed false positive `io.EOF` errors when the data was fully read
259259
- Avoid panics on reuse of closed connections
260260
- Fixed empty string producing false nil values

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ Passwords can consist of any character. Escaping is **not** necessary.
127127

128128
#### Protocol
129129
See [net.Dial](https://golang.org/pkg/net/#Dial) for more information which networks are available.
130-
In general you should use an Unix domain socket if available and TCP otherwise for best performance.
130+
In general you should use a Unix domain socket if available and TCP otherwise for best performance.
131131

132132
#### Address
133133
For TCP and UDP networks, addresses have the form `host[:port]`.

auth.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ func (mc *mysqlConn) handleAuthResult(oldAuthData []byte, plugin string) error {
338338

339339
switch plugin {
340340

341-
// https://insidemysql.com/preparing-your-community-connector-for-mysql-8-part-2-sha256/
341+
// https://dev.mysql.com/blog-archive/preparing-your-community-connector-for-mysql-8-part-2-sha256/
342342
case "caching_sha2_password":
343343
switch len(authData) {
344344
case 0:
@@ -376,7 +376,7 @@ func (mc *mysqlConn) handleAuthResult(oldAuthData []byte, plugin string) error {
376376
}
377377

378378
if data[0] != iAuthMoreData {
379-
return fmt.Errorf("unexpect resp from server for caching_sha2_password perform full authentication")
379+
return fmt.Errorf("unexpected resp from server for caching_sha2_password, perform full authentication")
380380
}
381381

382382
// parse public key

driver_test.go

+5-5
Original file line numberDiff line numberDiff line change
@@ -1198,7 +1198,7 @@ func TestLongData(t *testing.T) {
11981198
dbt.Fatalf("LONGBLOB: length in: %d, length out: %d", len(inS), len(out))
11991199
}
12001200
if rows.Next() {
1201-
dbt.Error("LONGBLOB: unexpexted row")
1201+
dbt.Error("LONGBLOB: unexpected row")
12021202
}
12031203
} else {
12041204
dbt.Fatalf("LONGBLOB: no data")
@@ -1217,7 +1217,7 @@ func TestLongData(t *testing.T) {
12171217
dbt.Fatalf("LONGBLOB: length in: %d, length out: %d", len(in), len(out))
12181218
}
12191219
if rows.Next() {
1220-
dbt.Error("LONGBLOB: unexpexted row")
1220+
dbt.Error("LONGBLOB: unexpected row")
12211221
}
12221222
} else {
12231223
if err = rows.Err(); err != nil {
@@ -1293,7 +1293,7 @@ func TestLoadData(t *testing.T) {
12931293
dbt.Fatalf("unexpected row count: got %d, want 0", count)
12941294
}
12951295

1296-
// Then fille File with data and try to load it
1296+
// Then fill File with data and try to load it
12971297
file.WriteString("1\ta string\n2\ta string containing a \\t\n3\ta string containing a \\n\n4\ta string containing both \\t\\n\n")
12981298
file.Close()
12991299
dbt.mustExec(fmt.Sprintf("LOAD DATA LOCAL INFILE %q INTO TABLE test", file.Name()))
@@ -1899,7 +1899,7 @@ func TestConcurrent(t *testing.T) {
18991899
}(i)
19001900
}
19011901

1902-
// wait until all conections are open
1902+
// wait until all connections are open
19031903
wg.Wait()
19041904

19051905
if fatalError != "" {
@@ -1948,7 +1948,7 @@ func TestCustomDial(t *testing.T) {
19481948
t.Skipf("MySQL server not running on %s", netAddr)
19491949
}
19501950

1951-
// our custom dial function which justs wraps net.Dial here
1951+
// our custom dial function which just wraps net.Dial here
19521952
RegisterDialContext("mydial", func(ctx context.Context, addr string) (net.Conn, error) {
19531953
var d net.Dialer
19541954
return d.DialContext(ctx, prot, addr)

dsn_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ func TestDSNReformat(t *testing.T) {
132132
dsn2 := cfg1.FormatDSN()
133133
if dsn2 != dsn1 {
134134
// Just log
135-
t.Logf("%d. %q reformated as %q", i, dsn1, dsn2)
135+
t.Logf("%d. %q reformatted as %q", i, dsn1, dsn2)
136136
}
137137

138138
cfg2, err := ParseDSN(dsn2)

packets.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ func (mc *mysqlConn) readHandshakePacket() (data []byte, plugin string, err erro
240240
// reserved (all [00]) [10 bytes]
241241
pos += 1 + 2 + 2 + 1 + 10
242242

243-
// second part of the password cipher [mininum 13 bytes],
243+
// second part of the password cipher [minimum 13 bytes],
244244
// where len=MAX(13, length of auth-plugin-data - 8)
245245
//
246246
// The web documentation is ambiguous about the length. However,
@@ -538,7 +538,7 @@ func (mc *mysqlConn) readAuthResult() ([]byte, string, error) {
538538
}
539539
}
540540

541-
// Returns error if Packet is not an 'Result OK'-Packet
541+
// Returns error if Packet is not a 'Result OK'-Packet
542542
func (mc *okHandler) readResultOK() error {
543543
data, err := mc.conn().readPacket()
544544
if err != nil {
@@ -647,7 +647,7 @@ func (mc *mysqlConn) resultUnchanged() *okHandler {
647647
// Both return an instance of type *okHandler.
648648
type okHandler mysqlConn
649649

650-
// Exposees the underlying type's methods.
650+
// Exposes the underlying type's methods.
651651
func (mc *okHandler) conn() *mysqlConn {
652652
return (*mysqlConn)(mc)
653653
}

packets_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ func TestReadPacketSplit(t *testing.T) {
188188
data[4] = 0x11
189189
data[maxPacketSize+3] = 0x22
190190

191-
// 2nd packet has payload length 0 and squence id 1
191+
// 2nd packet has payload length 0 and sequence id 1
192192
// 00 00 00 01
193193
data[pkt2ofs+3] = 0x01
194194

@@ -220,7 +220,7 @@ func TestReadPacketSplit(t *testing.T) {
220220
data[pkt2ofs+4] = 0x33
221221
data[pkt2ofs+maxPacketSize+3] = 0x44
222222

223-
// 3rd packet has payload length 0 and squence id 2
223+
// 3rd packet has payload length 0 and sequence id 2
224224
// 00 00 00 02
225225
data[pkt3ofs+3] = 0x02
226226

0 commit comments

Comments
 (0)