mirror of
				https://github.com/superseriousbusiness/gotosocial.git
				synced 2025-10-30 19:52:25 -05:00 
			
		
		
		
	[chore]: Bump github.com/miekg/dns from 1.1.51 to 1.1.52 (#1636)
Bumps [github.com/miekg/dns](https://github.com/miekg/dns) from 1.1.51 to 1.1.52. - [Release notes](https://github.com/miekg/dns/releases) - [Changelog](https://github.com/miekg/dns/blob/master/Makefile.release) - [Commits](https://github.com/miekg/dns/compare/v1.1.51...v1.1.52) --- updated-dependencies: - dependency-name: github.com/miekg/dns dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
		
					parent
					
						
							
								78aebf5088
							
						
					
				
			
			
				commit
				
					
						276d773438
					
				
			
		
					 17 changed files with 443 additions and 176 deletions
				
			
		
							
								
								
									
										31
									
								
								vendor/github.com/miekg/dns/msg.go
									
										
									
										generated
									
									
										vendored
									
									
								
							
							
						
						
									
										31
									
								
								vendor/github.com/miekg/dns/msg.go
									
										
									
										generated
									
									
										vendored
									
									
								
							|  | @ -448,7 +448,7 @@ Loop: | |||
| 	return string(s), off1, nil | ||||
| } | ||||
| 
 | ||||
| func packTxt(txt []string, msg []byte, offset int, tmp []byte) (int, error) { | ||||
| func packTxt(txt []string, msg []byte, offset int) (int, error) { | ||||
| 	if len(txt) == 0 { | ||||
| 		if offset >= len(msg) { | ||||
| 			return offset, ErrBuf | ||||
|  | @ -458,10 +458,7 @@ func packTxt(txt []string, msg []byte, offset int, tmp []byte) (int, error) { | |||
| 	} | ||||
| 	var err error | ||||
| 	for _, s := range txt { | ||||
| 		if len(s) > len(tmp) { | ||||
| 			return offset, ErrBuf | ||||
| 		} | ||||
| 		offset, err = packTxtString(s, msg, offset, tmp) | ||||
| 		offset, err = packTxtString(s, msg, offset) | ||||
| 		if err != nil { | ||||
| 			return offset, err | ||||
| 		} | ||||
|  | @ -469,32 +466,30 @@ func packTxt(txt []string, msg []byte, offset int, tmp []byte) (int, error) { | |||
| 	return offset, nil | ||||
| } | ||||
| 
 | ||||
| func packTxtString(s string, msg []byte, offset int, tmp []byte) (int, error) { | ||||
| func packTxtString(s string, msg []byte, offset int) (int, error) { | ||||
| 	lenByteOffset := offset | ||||
| 	if offset >= len(msg) || len(s) > len(tmp) { | ||||
| 	if offset >= len(msg) || len(s) > 256*4+1 /* If all \DDD */ { | ||||
| 		return offset, ErrBuf | ||||
| 	} | ||||
| 	offset++ | ||||
| 	bs := tmp[:len(s)] | ||||
| 	copy(bs, s) | ||||
| 	for i := 0; i < len(bs); i++ { | ||||
| 	for i := 0; i < len(s); i++ { | ||||
| 		if len(msg) <= offset { | ||||
| 			return offset, ErrBuf | ||||
| 		} | ||||
| 		if bs[i] == '\\' { | ||||
| 		if s[i] == '\\' { | ||||
| 			i++ | ||||
| 			if i == len(bs) { | ||||
| 			if i == len(s) { | ||||
| 				break | ||||
| 			} | ||||
| 			// check for \DDD | ||||
| 			if i+2 < len(bs) && isDigit(bs[i]) && isDigit(bs[i+1]) && isDigit(bs[i+2]) { | ||||
| 				msg[offset] = dddToByte(bs[i:]) | ||||
| 			if i+2 < len(s) && isDigit(s[i]) && isDigit(s[i+1]) && isDigit(s[i+2]) { | ||||
| 				msg[offset] = dddStringToByte(s[i:]) | ||||
| 				i += 2 | ||||
| 			} else { | ||||
| 				msg[offset] = bs[i] | ||||
| 				msg[offset] = s[i] | ||||
| 			} | ||||
| 		} else { | ||||
| 			msg[offset] = bs[i] | ||||
| 			msg[offset] = s[i] | ||||
| 		} | ||||
| 		offset++ | ||||
| 	} | ||||
|  | @ -1065,8 +1060,8 @@ func (dns *Msg) CopyTo(r1 *Msg) *Msg { | |||
| 	r1.Compress = dns.Compress | ||||
| 
 | ||||
| 	if len(dns.Question) > 0 { | ||||
| 		r1.Question = make([]Question, len(dns.Question)) | ||||
| 		copy(r1.Question, dns.Question) // TODO(miek): Question is an immutable value, ok to do a shallow-copy | ||||
| 		// TODO(miek): Question is an immutable value, ok to do a shallow-copy | ||||
| 		r1.Question = cloneSlice(dns.Question) | ||||
| 	} | ||||
| 
 | ||||
| 	rrArr := make([]RR, len(dns.Answer)+len(dns.Ns)+len(dns.Extra)) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue