Skip to content
Snippets Groups Projects
Select Git revision
  • 2bd97d4345f221293e4fa3a264881ed9aafd09c7
  • master default protected
2 results

test_fsig.py

Blame
  • smartctl.c 20.47 KiB
    /*
     * smartctl.c
     *
     * Home page of code is: http://smartmontools.sourceforge.net
     *
     * Copyright (C) 2002 Bruce Allen <smartmontools-support@lists.sourceforge.net>
     * Copyright (C) 2000 Michael Cornwell <cornwell@acm.org>
     *
     * This program 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, or (at your option)
     * any later version.
     *
     * You should have received a copy of the GNU General Public License
     * (for example COPYING); if not, write to the Free
     * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
     *
     * This code was originally developed as a Senior Thesis by Michael Cornwell
     * at the Concurrent Systems Laboratory (now part of the Storage Systems
     * Research Center), Jack Baskin School of Engineering, University of
     * California, Santa Cruz. http://ssrc.soe.ucsc.edu/
     *
     */
    
    
    #include <stdio.h>
    #include <unistd.h>
    #include <sys/ioctl.h>
    #include <linux/hdreg.h>
    #include <sys/fcntl.h>
    #include <sys/types.h>
    #include <string.h>
    #include <stdarg.h>
    #ifdef HAVE_GETOPT_H
    #include <getopt.h>
    #endif
    #include "smartctl.h"
    #include "atacmds.h"
    #include "ataprint.h"
    #include "scsicmds.h"
    #include "scsiprint.h"
    #include "extern.h"
    
    extern const char *CVSid1, *CVSid2, *CVSid3, *CVSid4; 
    const char* CVSid5="$Id: smartctl.c,v 1.47 2003/01/07 19:47:24 pjwilliams Exp $"
    CVSID1 CVSID2 CVSID3 CVSID4 CVSID5 CVSID6;
    
    // This is a block containing all the "control variables".  We declare
    // this globally in this file, and externally in other files.
    atamainctrl *con=NULL;
    
    void printslogan(){
      pout("smartctl version %d.%d-%d Copyright (C) 2002 Bruce Allen\n",
          (int)RELEASE_MAJOR, (int)RELEASE_MINOR, (int)SMARTMONTOOLS_VERSION);
      pout("Home page is %s\n\n",PROJECTHOME);
      return;
    }
    
    
    void printcopy(){
      char out[CVSMAXLEN];
      pout("smartctl comes with ABSOLUTELY NO WARRANTY. This\n");
      pout("is free software, and you are welcome to redistribute it\n");
      pout("under the terms of the GNU General Public License Version 2.\n");
      pout("See http://www.gnu.org for further details.\n\n");
      pout("CVS version IDs of files used to build this code are:\n");
      printone(out,CVSid1);
      pout("%s",out);
      printone(out,CVSid2);
      pout("%s",out);