summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/utils/smbtree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/utils/smbtree.c b/source3/utils/smbtree.c
index 5c07b122b2..76ee6489b9 100644
--- a/source3/utils/smbtree.c
+++ b/source3/utils/smbtree.c
@@ -209,7 +209,7 @@ static bool get_rpc_shares(struct cli_state *cli,
return False;
}
- for (i=0; i<total_entries; i++) {
+ for (i=0; i < info_ctr.ctr.ctr1->count; i++) {
struct srvsvc_NetShareInfo1 info = info_ctr.ctr.ctr1->array[i];
fn(info.name, info.type, info.comment, state);
}