IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 31, 2007, 4:40:05 PM (19 years ago)
Author:
jhoblitt
Message:

required option update

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTools/src/chiptool.c

    r12237 r13580  
    2424#include <stdio.h>
    2525#include <string.h>
     26#include <stdint.h>
    2627#include <stdlib.h>
     28#include <math.h>
    2729
    2830#include "pxtools.h"
     
    599601
    600602    bool status = false;
    601     psS8 code = psMetadataLookupS8(&status, config->args, "-code");
     603    psS16 code = psMetadataLookupS16(&status, config->args, "-code");
    602604    if (!status) {
    603605        psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -code");
     606        return false;
     607    }
     608    if (code == INT16_MAX) {
     609        psError(PS_ERR_UNKNOWN, true, "-code is required");
    604610        return false;
    605611    }
     
    831837        return false;
    832838    }
    833     if (!uri) {
    834         psError(PS_ERR_UNKNOWN, true, "-uri is required");
    835         return false;
    836     }
    837839
    838840    psF64 bg = psMetadataLookupF64(&status, config->args, "-bg");
     
    862864
    863865    // default values
    864     psS8 code = psMetadataLookupS8(&status, config->args, "-code");
     866    psS16 code = psMetadataLookupS16(&status, config->args, "-code");
    865867    if (!status) {
    866868        psError(PS_ERR_UNKNOWN, false, "failed to lookup value for -code");
Note: See TracChangeset for help on using the changeset viewer.