Skip to content

Commit

Permalink
Add debug logs
Browse files Browse the repository at this point in the history
  • Loading branch information
jacobwgillespie committed Jul 28, 2022
1 parent 425fd9f commit 7cc14a4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/mounts/mounts.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,11 @@ func WaitForDevice(device string) error {
log.Printf("Waiting for device %s\n", device)
path, err := os.Readlink(device)
if err == nil {
if info, err := os.Stat(path); err == nil && info.Mode()&os.ModeDevice != 0 {
info, err := os.Stat(path)
fmt.Printf("%+v\n", info)
fmt.Printf("%+v\n", err)
fmt.Printf("%+v\n", info.Mode()&os.ModeDevice)
if err == nil && info.Mode()&os.ModeDevice != 0 {
return nil
}
}
Expand Down

0 comments on commit 7cc14a4

Please sign in to comment.