[aoe] Rename aoe__mount_targets to AOE_S_MOUNT_TARGETS
authorShao Miller <Shao.Miller@yrdsb.edu.on.ca>
Sun, 2 Jan 2011 05:00:30 +0000 (00:00 -0500)
committerShao Miller <Shao.Miller@yrdsb.edu.on.ca>
Sun, 2 Jan 2011 05:00:30 +0000 (00:00 -0500)
src/aoe/driver.c
src/include/aoe.h
src/util/winvblk.c

index 91c38af..2ade653 100644 (file)
@@ -1644,7 +1644,7 @@ NTSTATUS STDCALL AoeBusDevCtlScan(IN PIRP irp) {
     KIRQL irql;
     winvblock__uint32 count;
     AOE_SP_TARGET_LIST_ target_walker;
-    aoe__mount_targets_ptr targets;
+    AOE_S_MOUNT_TARGETS_ptr targets;
     PIO_STACK_LOCATION io_stack_loc = IoGetCurrentIrpStackLocation(irp);
 
     DBG("Got IOCTL_AOE_SCAN...\n");
@@ -1667,7 +1667,7 @@ NTSTATUS STDCALL AoeBusDevCtlScan(IN PIRP irp) {
           );
       }
     irp->IoStatus.Information =
-      sizeof (aoe__mount_targets) + (count * sizeof (aoe__mount_target));
+      sizeof (AOE_S_MOUNT_TARGETS) + (count * sizeof (aoe__mount_target));
     targets->Count = count;
 
     count = 0;
@@ -1685,9 +1685,9 @@ NTSTATUS STDCALL AoeBusDevCtlScan(IN PIRP irp) {
         irp->AssociatedIrp.SystemBuffer,
         targets,
         (io_stack_loc->Parameters.DeviceIoControl.OutputBufferLength <
-          (sizeof (aoe__mount_targets) + (count * sizeof (aoe__mount_target))) ?
+          (sizeof (AOE_S_MOUNT_TARGETS) + (count * sizeof (aoe__mount_target))) ?
           io_stack_loc->Parameters.DeviceIoControl.OutputBufferLength :
-          (sizeof (aoe__mount_targets) + (count * sizeof (aoe__mount_target)))
+          (sizeof (AOE_S_MOUNT_TARGETS) + (count * sizeof (aoe__mount_target)))
         )
       );
     wv_free(targets);
index 4a24118..7a5986d 100644 (file)
@@ -1,5 +1,5 @@
 /**
- * Copyright (C) 2009-2010, Shao Miller <shao.miller@yrdsb.edu.on.ca>.
+ * Copyright (C) 2009-2011, Shao Miller <shao.miller@yrdsb.edu.on.ca>.
  * Copyright 2006-2008, V.
  * For WinAoE contact information, see http://winaoe.org/
  *
@@ -71,11 +71,10 @@ winvblock__def_struct(aoe__mount_target)
     LARGE_INTEGER ProbeTime;
   };
 
-winvblock__def_struct(aoe__mount_targets)
-  {
+typedef struct AOE_MOUNT_TARGETS {
     winvblock__uint32 Count;
     aoe__mount_target Target[];
-  };
+  } AOE_S_MOUNT_TARGETS, * AOE_SP_MOUNT_TARGETS;
 
 winvblock__def_struct(aoe__mount_disk)
   {
index 9d63f2b..f97b65d 100644 (file)
@@ -223,14 +223,14 @@ Parameters:\n\
   }
 
 static int STDCALL cmd_scan(void) {
-    aoe__mount_targets_ptr targets;
+    AOE_S_MOUNT_TARGETS_ptr targets;
     DWORD bytes_returned;
     winvblock__uint32 i;
     winvblock__uint8 string[256];
     int status = 2;
 
     targets = malloc(
-        sizeof (aoe__mount_targets) +
+        sizeof (AOE_S_MOUNT_TARGETS) +
         (32 * sizeof (aoe__mount_target))
       );
     if (targets == NULL) {
@@ -244,7 +244,7 @@ static int STDCALL cmd_scan(void) {
         NULL,
         0,
         targets,
-        sizeof (aoe__mount_targets) + (32 * sizeof (aoe__mount_target)),
+        sizeof (AOE_S_MOUNT_TARGETS) + (32 * sizeof (aoe__mount_target)),
         &bytes_returned,
         (LPOVERLAPPED) NULL
       )) {