+/* vim: set noexpandtab tabstop=4 shiftwidth=4:
+ *----------------------------------------------------------------------------
+ * emufs
+ *----------------------------------------------------------------------------
+ * This file is part of emufs.
+ *
+ * emufs is free software; you can redistribute it and/or modify it under the
+ * terms of the GNU General Public License as published by the Free Software
+ * Foundation; either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * emufs is distributed in the hope that it will be useful, but WITHOUT ANY
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with emufs; if not, write to the Free Software Foundation, Inc., 59 Temple
+ * Place, Suite 330, Boston, MA 02111-1307 USA
+ *----------------------------------------------------------------------------
+ * Creado: mié mar 31 17:26:46 ART 2004
+ * Autores: Nicolás Dimov <sagardua@uolsinectis.com.ar>
+ *----------------------------------------------------------------------------
+ *
+ * $Id$
+ *
+ */
+
+/** \file
+ *
+ * Prueba de archivo \ref tipo3.h "tipo3".
+ *
+ */
+
#include <stdio.h>
#include <string.h>
#include "emufs.h"
+
int main(int argc, char *argv[])
{
EMUFS *fp;
- int n1, n2, n3, n4, n5, n6, n7, n8;
+ EMUFS_REG_ID n1, n2, n3, n4, n5, n6, n7, n8;
char a[100];
char b[100];
char c[100];
n1 = fp->grabar_registro(fp, a, 100);
n2 = fp->grabar_registro(fp, c, 100);
- n3 = fp->grabar_registro(fp, d, 100);
+ /*n3 = fp->grabar_registro(fp, d, 100);
n4 = fp->grabar_registro(fp, e, 100);
n5 = fp->grabar_registro(fp, f, 100);
n6 = fp->grabar_registro(fp, g, 100);
n7 = fp->grabar_registro(fp, h, 100);
+ n8 = fp->grabar_registro(fp, i, 100);*/
+ printf("ID0 = %lu\n", n1);
+ printf("ID1 = %lu\n", n2);
+ printf("ID2 = %lu\n", n3);
+ printf("ID3 = %lu\n", n4);
+ printf("ID4 = %lu\n", n5);
+ printf("ID5 = %lu\n", n6);
+ printf("ID6 = %lu\n", n7);
- printf("ID0 = %d\n", n1);
- printf("ID1 = %d\n", n2);
- printf("ID2 = %d\n", n3);
- printf("ID3 = %d\n", n4);
- printf("ID4 = %d\n", n5);
- printf("ID5 = %d\n", n6);
- printf("ID6 = %d\n", n7);
-
-
- fp->borrar_registro(fp, n4, 100);
- n8 = fp->grabar_registro(fp, i, 100);
- fp->leer_registro(fp, n8, b, 100);
+ ver_archivo_FS(fp);
+ /*fp->borrar_registro(fp, n4, 100);
+ fp->borrar_registro(fp, n2, 100);
+ fp->borrar_registro(fp, n6, 100);*/
+ fp->borrar_registro(fp, n1);
+ printf("borre el registro de id = %d\n",n1);
+ fp->leer_registro(fp, n2, b, 100);
printf("Recuperado : %s\n", b);