pe.c 840 B

1234567891011121314151617181920212223242526272829303132
  1. /* vi: set sw=4 ts=4: */
  2. /*
  3. * pe.c - Print a second extended filesystem errors behavior
  4. *
  5. * Copyright (C) 1992, 1993, 1994 Remy Card <card@masi.ibp.fr>
  6. * Laboratoire MASI, Institut Blaise Pascal
  7. * Universite Pierre et Marie Curie (Paris VI)
  8. *
  9. * This file can be redistributed under the terms of the GNU Library General
  10. * Public License
  11. */
  12. /*
  13. * History:
  14. * 94/01/09 - Creation
  15. */
  16. #include <stdio.h>
  17. #include "e2p.h"
  18. void print_fs_errors(FILE *f, unsigned short errors)
  19. {
  20. char *disp = NULL;
  21. switch (errors) {
  22. case EXT2_ERRORS_CONTINUE: disp = "Continue"; break;
  23. case EXT2_ERRORS_RO: disp = "Remount read-only"; break;
  24. case EXT2_ERRORS_PANIC: disp = "Panic"; break;
  25. default: disp = "Unknown (continue)";
  26. }
  27. fprintf(f, disp);
  28. }