Skip to content

Commit

Permalink
temp revert back to un-trimmed code (#16)
Browse files Browse the repository at this point in the history
* trim device usb strings, git ignore .vscode folder

* temp revert back to un-trimmed code
  • Loading branch information
jpoirier committed Jun 7, 2016
1 parent 52182a2 commit dddf87f
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions rtlsdr.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
package rtlsdr

import (
"bytes"
"errors"
"unsafe"
)
Expand Down Expand Up @@ -197,8 +196,7 @@ func GetDeviceUsbStrings(index int) (manufact, product, serial string, err error
(*C.char)(unsafe.Pointer(&m[0])),
(*C.char)(unsafe.Pointer(&p[0])),
(*C.char)(unsafe.Pointer(&s[0]))))
return string(bytes.Trim(m, "\x00")), string(bytes.Trim(p, "\x00")),
string(bytes.Trim(s, "\x00")), libError(i)
return string(m), string(p), string(s), libError(i)
}

// GetIndexBySerial returns a device index by serial id.
Expand Down

0 comments on commit dddf87f

Please sign in to comment.