소스 검색

Merge pull request #72 from rauls5382/procmaps

Add comment for ParseMemoryMapFromScanner
Raul Silvera 8 년 전
부모
커밋
074a40a2dd
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4
    0
      profile/legacy_profile.go

+ 4
- 0
profile/legacy_profile.go 파일 보기

@@ -1015,6 +1015,10 @@ func (p *Profile) ParseMemoryMap(rd io.Reader) error {
1015 1015
 	return p.ParseMemoryMapFromScanner(bufio.NewScanner(rd))
1016 1016
 }
1017 1017
 
1018
+// ParseMemoryMapFromScanner parses a memory map in the format of
1019
+// /proc/self/maps or a variety of legacy format, and overrides the
1020
+// mappings in the current profile.  It renumbers the samples and
1021
+// locations in the profile correspondingly.
1018 1022
 func (p *Profile) ParseMemoryMapFromScanner(s *bufio.Scanner) error {
1019 1023
 	mapping, err := parseProcMapsFromScanner(s)
1020 1024
 	if err != nil {