[brlcad-commits] SF.net SVN: brlcad:[37717] brlcad/trunk
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: <d_r...@us...> - 2010-02-23 09:03:16
|
Revision: 37717 http://brlcad.svn.sourceforge.net/brlcad/?rev=37717&view=rev Author: d_rossberg Date: 2010-02-23 09:03:08 +0000 (Tue, 23 Feb 2010) Log Message: ----------- another iteration step in forcing back ssize_t: removed all references from the headers (exept for the declaration) poorly tested Modified Paths: -------------- brlcad/trunk/include/bu.h brlcad/trunk/include/db5.h brlcad/trunk/include/raytrace.h brlcad/trunk/include/rtgeom.h brlcad/trunk/src/libbu/parse.c brlcad/trunk/src/librt/db5_bin.c brlcad/trunk/src/librt/db5_comb.c brlcad/trunk/src/librt/db5_io.c brlcad/trunk/src/librt/db5_scan.c brlcad/trunk/src/librt/db_alloc.c brlcad/trunk/src/librt/db_comb.c brlcad/trunk/src/librt/db_io.c brlcad/trunk/src/librt/db_walk.c brlcad/trunk/src/librt/primitives/arbn/arbn.c brlcad/trunk/src/librt/primitives/bot/bot.c brlcad/trunk/src/librt/primitives/pipe/pipe.c brlcad/trunk/src/librt/primitives/poly/poly.c brlcad/trunk/src/librt/primitives/poly/poly_mirror.c Modified: brlcad/trunk/include/bu.h =================================================================== --- brlcad/trunk/include/bu.h 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/include/bu.h 2010-02-23 09:03:08 UTC (rev 37717) @@ -1861,9 +1861,9 @@ */ struct bu_structparse { char sp_fmt[4]; /**< @brief "i" or "%f", etc */ - ssize_t sp_count; /**< @brief number of elements */ + size_t sp_count; /**< @brief number of elements */ char *sp_name; /**< @brief Element's symbolic name */ - ssize_t sp_offset; /**< @brief Byte offset in struct */ + size_t sp_offset; /**< @brief Byte offset in struct */ void (*sp_hook)(); /**< @brief Optional hooked function, or indir ptr */ char *sp_desc; /**< @brief description of element */ void *sp_default; /**< @brief ptr to default value */ @@ -1884,7 +1884,7 @@ */ struct bu_external { unsigned long ext_magic; - ssize_t ext_nbytes; + size_t ext_nbytes; genptr_t ext_buf; }; #define BU_INIT_EXTERNAL(_p) {(_p)->ext_magic = BU_EXTERNAL_MAGIC; \ Modified: brlcad/trunk/include/db5.h =================================================================== --- brlcad/trunk/include/db5.h 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/include/db5.h 2010-02-23 09:03:08 UTC (rev 37717) @@ -199,7 +199,7 @@ unsigned char b_zzz; unsigned char major_type; unsigned char minor_type; - ssize_t object_length; /* in bytes, on disk */ + size_t object_length; /* in bytes, on disk */ /* These three MUST NOT be passed to bu_free_external()! */ struct bu_external name; struct bu_external body; Modified: brlcad/trunk/include/raytrace.h =================================================================== --- brlcad/trunk/include/raytrace.h 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/include/raytrace.h 2010-02-23 09:03:08 UTC (rev 37717) @@ -778,8 +778,8 @@ /* THESE ELEMENTS ARE FOR LIBRT ONLY, AND MAY CHANGE */ struct directory * dbi_Head[RT_DBNHASH]; FILE * dbi_fp; /**< @brief standard file pointer */ - ssize_t dbi_eof; /**< @brief End+1 pos after db_scan() */ - ssize_t dbi_nrec; /**< @brief # records after db_scan() */ + size_t dbi_eof; /**< @brief End+1 pos after db_scan() */ + size_t dbi_nrec; /**< @brief # records after db_scan() */ int dbi_uses; /**< @brief # of uses of this struct */ struct mem_map * dbi_freep; /**< @brief map of free granules */ genptr_t dbi_inmem; /**< @brief ptr to in-memory copy */ @@ -802,7 +802,7 @@ * One of these structures is allocated in memory to represent each * named object in the database. * - * Note that a d_addr of RT_DIR_PHONY_ADDR (-1L) means that database + * Note that a d_addr of RT_DIR_PHONY_ADDR ((size_t)-1) means that database * storage has not been allocated yet. * * Note that there is special handling for RT_DIR_INMEM "in memory" @@ -827,13 +827,13 @@ unsigned long d_magic; /**< @brief Magic number */ char * d_namep; /**< @brief pointer to name string */ union { - ssize_t file_offset; /**< @brief disk address in obj file */ + size_t file_offset; /**< @brief disk address in obj file */ genptr_t ptr; /**< @brief ptr to in-memory-only obj */ } d_un; struct directory * d_forw; /**< @brief link to next dir entry */ struct animate * d_animate; /**< @brief link to animation */ long d_uses; /**< @brief # uses, from instancing */ - ssize_t d_len; /**< @brief # of db granules used */ + size_t d_len; /**< @brief # of db granules used */ long d_nref; /**< @brief # times ref'ed by COMBs */ int d_flags; /**< @brief flags */ unsigned char d_major_type; /**< @brief object major type */ @@ -845,7 +845,7 @@ #define RT_CK_DIR(_dp) BU_CKMAG(_dp, RT_DIR_MAGIC, "(librt)directory") #define d_addr d_un.file_offset -#define RT_DIR_PHONY_ADDR (-1L) /**< @brief Special marker for d_addr field */ +#define RT_DIR_PHONY_ADDR ((size_t)-1) /**< @brief Special marker for d_addr field */ /* flags for db_diradd() and friends */ #define RT_DIR_SOLID 0x1 /**< @brief this name is a solid */ @@ -2727,12 +2727,12 @@ (struct bu_external *ep, long length)); RT_EXPORT BU_EXTERN(int db5_decode_signed, - (ssize_t *lenp, + (size_t *lenp, const unsigned char *cp, int format)); RT_EXPORT BU_EXTERN(int db5_decode_length, - (ssize_t *lenp, + (size_t *lenp, const unsigned char *cp, int format)); @@ -2880,8 +2880,8 @@ RT_EXPORT BU_EXTERN(int db_write, (struct db_i *dbip, const genptr_t addr, - ssize_t count, - ssize_t offset)); + size_t count, + size_t offset)); RT_EXPORT BU_EXTERN(int db_fwrite_external, (FILE *fp, const char *name, Modified: brlcad/trunk/include/rtgeom.h =================================================================== --- brlcad/trunk/include/rtgeom.h 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/include/rtgeom.h 2010-02-23 09:03:08 UTC (rev 37717) @@ -196,7 +196,7 @@ */ struct rt_pg_internal { unsigned long magic; - ssize_t npoly; + size_t npoly; struct rt_pg_face_internal { int npts; /**< @brief number of points for this polygon */ fastf_t *verts; /**< @brief has 3*npts elements */ Modified: brlcad/trunk/src/libbu/parse.c =================================================================== --- brlcad/trunk/src/libbu/parse.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/libbu/parse.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -67,8 +67,8 @@ } #define BU_CK_GETPUT(_p) {\ - register ssize_t _i; \ - register ssize_t _len; \ + register size_t _i; \ + register size_t _len; \ BU_CK_EXTERNAL(_p); \ if (!(_p->ext_buf)) { \ bu_log("ERROR: BU_CK_GETPUT null ext_buf, file %s, line %d\n", \ @@ -569,7 +569,7 @@ /* string containing value */ { register char *loc; - ssize_t i; + size_t i; int retval = 0; for (; sdp->sp_name != (char *)0; sdp++) { @@ -602,7 +602,7 @@ case 'c': case 's': { - register ssize_t j; + register size_t j; /* copy the string, converting escaped double * quotes to just double quotes @@ -2020,7 +2020,7 @@ { const unsigned char *cp; const unsigned char *endp; - ssize_t i, j, k; + size_t i, j, k; BU_CK_EXTERNAL(ep); @@ -2100,7 +2100,7 @@ bu_structparse_get_terse_form(struct bu_vls *logstr, const struct bu_structparse *sp) { struct bu_vls str; - ssize_t i; + size_t i; bu_vls_init(&str); @@ -2144,8 +2144,8 @@ { register char *cp, *loc; register const struct bu_structparse *sdp; - register ssize_t j; - register ssize_t ii; + register size_t j; + register size_t ii; struct bu_vls str; if (desc == (struct bu_structparse *)NULL) { Modified: brlcad/trunk/src/librt/db5_bin.c =================================================================== --- brlcad/trunk/src/librt/db5_bin.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db5_bin.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -533,7 +533,7 @@ { register struct rt_binunif_internal *bip=(struct rt_binunif_internal *)intern->idb_ptr; struct bu_external ext; - ssize_t i; + size_t i; unsigned char *c; RT_CHECK_BINUNIF( bip ); Modified: brlcad/trunk/src/librt/db5_comb.c =================================================================== --- brlcad/trunk/src/librt/db5_comb.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db5_comb.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -455,8 +455,8 @@ struct rt_comb_internal *comb; unsigned char *cp; int wid; - ssize_t nmat, nleaf, rpn_len, max_stack_depth; - ssize_t leafbytes; + size_t nmat, nleaf, rpn_len, max_stack_depth; + size_t leafbytes; unsigned char *matp; unsigned char *leafp; unsigned char *leafp_end; @@ -465,7 +465,7 @@ union tree *stack[MAX_V5_STACK]; union tree **sp; /* stack pointer */ const char *ap; - ssize_t i; + size_t ius; RT_CK_DB_INTERNAL( ip ); BU_CK_EXTERNAL(ep); @@ -495,6 +495,8 @@ leafp_end = exprp; if ( rpn_len == 0 ) { + ssize_t is; + /* This tree is all union operators, import it as a balanced tree */ struct bu_ptbl *tbl1, *tbl2; @@ -503,9 +505,9 @@ /* insert all the leaf nodes into a bu_ptbl */ bu_ptbl_init( tbl1, nleaf, "rt_comb_import5: tbl" ); - for ( i = nleaf-1; i >= 0; i-- ) { + for (is = nleaf-1; is >= 0; is-- ) { union tree *tp; - ssize_t mi; + size_t mi; RT_GET_TREE( tp, resp ); tp->tr_l.magic = RT_TREE_MAGIC; @@ -517,7 +519,7 @@ mi = 4095; /* sanity */ leafp += db5_decode_signed( &mi, leafp, wid ); - if ( mi < 0 ) { + if ( (ssize_t)mi < 0 ) { /* Signal identity matrix */ if ( !mat || bn_mat_is_identity( mat ) ) { tp->tr_l.tl_mat = (matp_t)NULL; @@ -559,12 +561,12 @@ while ( 1 ) { struct bu_ptbl *tmp; - for ( i=0; i<BU_PTBL_LEN( tbl1 ); i += 2 ) { + for ( is=0; is<BU_PTBL_LEN( tbl1 ); is += 2 ) { union tree *tp1, *tp2, *unionp; int j; - j = i + 1; - tp1 = (union tree *)BU_PTBL_GET( tbl1, i ); + j = is + 1; + tp1 = (union tree *)BU_PTBL_GET( tbl1, is ); if ( j < BU_PTBL_LEN( tbl1 ) ) { tp2 = (union tree *)BU_PTBL_GET( tbl1, j ); } else { @@ -620,9 +622,9 @@ } sp = &stack[0]; - for ( i=0; i < rpn_len; i++, exprp++ ) { + for ( ius=0; ius < rpn_len; ius++, exprp++ ) { union tree *tp; - ssize_t mi; + size_t mi; RT_GET_TREE( tp, resp ); tp->tr_b.magic = RT_TREE_MAGIC; @@ -637,7 +639,7 @@ mi = 4095; /* sanity */ leafp += db5_decode_signed( &mi, leafp, wid ); - if ( mi < 0 ) { + if ( (ssize_t)mi < 0 ) { /* Signal identity matrix */ if ( !mat || bn_mat_is_identity( mat ) ) { tp->tr_l.tl_mat = (matp_t)NULL; Modified: brlcad/trunk/src/librt/db5_io.c =================================================================== --- brlcad/trunk/src/librt/db5_io.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db5_io.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -112,7 +112,7 @@ * The number of bytes of input that were decoded. */ int -db5_decode_length(ssize_t *lenp, const unsigned char *cp, int format) +db5_decode_length(size_t *lenp, const unsigned char *cp, int format) { switch ( format ) { case DB5HDR_WIDTHCODE_8BIT: @@ -149,7 +149,7 @@ * The number of bytes of input that were decoded. */ int -db5_decode_signed(ssize_t *lenp, const unsigned char *cp, int format) +db5_decode_signed(size_t *lenp, const unsigned char *cp, int format) { switch ( format ) { case DB5HDR_WIDTHCODE_8BIT: @@ -790,7 +790,7 @@ void db5_export_attributes( struct bu_external *ext, const struct bu_attribute_value_set *avs ) { - int need = 0; + size_t need = 0; const struct bu_attribute_value_pair *avpp; char *cp; size_t i; Modified: brlcad/trunk/src/librt/db5_scan.c =================================================================== --- brlcad/trunk/src/librt/db5_scan.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db5_scan.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -88,7 +88,7 @@ addr += raw.object_length; } dbip->dbi_eof = addr; - BU_ASSERT_LONG(dbip->dbi_eof, ==, dbip->dbi_mf->buflen); + BU_ASSERT_LONG(dbip->dbi_eof, ==, (size_t)dbip->dbi_mf->buflen); } else { /* In a totally portable way, read the database with stdio */ rewind(dbip->dbi_fp); Modified: brlcad/trunk/src/librt/db_alloc.c =================================================================== --- brlcad/trunk/src/librt/db_alloc.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db_alloc.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -78,7 +78,7 @@ while (1) { if ( (addr = rt_memalloc( &(dbip->dbi_freep), (unsigned)count )) == 0L ) { /* No contiguous free block, append to file */ - if ( (dp->d_addr = dbip->dbi_eof) < 0 ) { + if ( (dp->d_addr = dbip->dbi_eof) == RT_DIR_PHONY_ADDR ) { bu_log("db_alloc: bad EOF\n"); return(-1); } Modified: brlcad/trunk/src/librt/db_comb.c =================================================================== --- brlcad/trunk/src/librt/db_comb.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db_comb.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -212,8 +212,8 @@ struct rt_tree_array *rt_tree_array; union tree *tree; struct rt_comb_internal *comb; - int j; - ssize_t node_count; + size_t j; + size_t node_count; BU_CK_EXTERNAL(ep); rp = (union record *)ep->ext_buf; Modified: brlcad/trunk/src/librt/db_io.c =================================================================== --- brlcad/trunk/src/librt/db_io.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db_io.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -50,18 +50,18 @@ * -1 FAILURE */ HIDDEN int -db_read(const struct db_i *dbip, genptr_t addr, ssize_t count, ssize_t offset) +db_read(const struct db_i *dbip, genptr_t addr, size_t count, size_t offset) /* byte count */ /* byte offset from start of file */ { - long int got; + size_t got; RT_CK_DBI(dbip); if (RT_G_DEBUG&DEBUG_DB) { bu_log("db_read(dbip=x%x, addr=x%x, count=%d., offset=x%x)\n", dbip, addr, count, offset); } - if (count <= 0 || offset < 0) { + if (count == 0) { return(-1); } if (offset+count > dbip->dbi_eof) { @@ -79,12 +79,12 @@ if (fseek(dbip->dbi_fp, offset, 0)) bu_bomb("db_read: fseek error\n"); - got = (long int)fread(addr, 1, count, dbip->dbi_fp); + got = fread(addr, 1, count, dbip->dbi_fp); bu_semaphore_release(BU_SEM_SYSCALL); if (got != count) { - if (got < 0) { + if (got == RT_DIR_PHONY_ADDR) { perror(dbip->dbi_filename); } bu_log("db_read(%s): read error. Wanted %d, got %d bytes\n", @@ -125,7 +125,7 @@ if (RT_G_DEBUG&DEBUG_DB) bu_log("db_getmrec(%s) x%x, x%x\n", dp->d_namep, dbip, dp); - if (dp->d_addr < 0) + if (dp->d_addr == RT_DIR_PHONY_ADDR) return((union record *)0); /* was dummy DB entry */ where = (union record *)bu_malloc( dp->d_len * sizeof(union record), @@ -165,11 +165,11 @@ if (RT_G_DEBUG&DEBUG_DB) bu_log("db_get(%s) x%x, x%x x%x off=%d len=%d\n", dp->d_namep, dbip, dp, where, offset, len); - if (dp->d_addr < 0) { + if (dp->d_addr == RT_DIR_PHONY_ADDR) { where->u_id = '\0'; /* undefined id */ return(-1); } - if (offset < 0 || offset+len > dp->d_len) { + if (offset < 0 || (size_t)(offset+len) > dp->d_len) { bu_log("db_get(%s): xfer %d..%x exceeds 0..%d\n", dp->d_namep, offset, offset+len, dp->d_len); where->u_id = '\0'; /* undefined id */ @@ -206,9 +206,9 @@ */ /* should be HIDDEN */ int -db_write(struct db_i *dbip, const genptr_t addr, ssize_t count, ssize_t offset) +db_write(struct db_i *dbip, const genptr_t addr, size_t count, size_t offset) { - register long int got; + register size_t got; RT_CK_DBI(dbip); if (RT_G_DEBUG&DEBUG_DB) { @@ -220,7 +220,7 @@ dbip->dbi_filename); return(-1); } - if (count <= 0 || offset < 0) { + if (count == 0) { return(-1); } if (dbip->dbi_inmem) { @@ -231,7 +231,7 @@ bu_suspend_interrupts(); (void)fseek(dbip->dbi_fp, offset, 0); - got = (long int)fwrite(addr, 1, count, dbip->dbi_fp); + got = fwrite(addr, 1, count, dbip->dbi_fp); fflush(dbip->dbi_fp); bu_restore_interrupts(); @@ -266,7 +266,7 @@ if (RT_G_DEBUG&DEBUG_DB) bu_log("db_put(%s) x%x, x%x x%x off=%d len=%d\n", dp->d_namep, dbip, dp, where, offset, len); - if (offset < 0 || offset+len > dp->d_len) { + if (offset < 0 || (size_t)(offset+len) > dp->d_len) { bu_log("db_put(%s): xfer %d..%x exceeds 0..%d\n", dp->d_namep, offset, offset+len, dp->d_len); return(-1); @@ -317,7 +317,7 @@ if (RT_G_DEBUG&DEBUG_DB) bu_log("db_get_external(%s) ep=x%x, dbip=x%x, dp=x%x\n", dp->d_namep, ep, dbip, dp); - if ((dp->d_flags & RT_DIR_INMEM) == 0 && dp->d_addr < 0) + if ((dp->d_flags & RT_DIR_INMEM) == 0 && dp->d_addr == RT_DIR_PHONY_ADDR) return(-1); /* was dummy DB entry */ BU_INIT_EXTERNAL(ep); @@ -384,7 +384,7 @@ return db_put_external5(ep, dp, dbip); if (dbip->dbi_version <= 4) { - ssize_t ngran; + size_t ngran; ngran = (ep->ext_nbytes+sizeof(union record)-1)/sizeof(union record); if (ngran != dp->d_len) { Modified: brlcad/trunk/src/librt/db_walk.c =================================================================== --- brlcad/trunk/src/librt/db_walk.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/db_walk.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -92,7 +92,7 @@ db_preorder_traverse( struct directory *dp, struct db_traverse *dtp ) { - register int i; + register size_t i; RT_CK_DBTR(dtp); RT_CK_DBI(dtp->dbip); @@ -209,7 +209,7 @@ struct resource *resp, genptr_t client_data) { - register int i; + register size_t i; RT_CK_DBI(dbip); Modified: brlcad/trunk/src/librt/primitives/arbn/arbn.c =================================================================== --- brlcad/trunk/src/librt/primitives/arbn/arbn.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/primitives/arbn/arbn.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -903,7 +903,7 @@ int i; unsigned long neqn; int double_count; - int byte_count; + size_t byte_count; RT_CK_DB_INTERNAL(ip); BU_CK_EXTERNAL(ep); Modified: brlcad/trunk/src/librt/primitives/bot/bot.c =================================================================== --- brlcad/trunk/src/librt/primitives/bot/bot.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/primitives/bot/bot.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -752,7 +752,7 @@ union record *rec; int i; int chars_used; - ssize_t num_recs; + size_t num_recs; struct bu_vls face_mode; if (dbip) RT_CK_DBI(dbip); Modified: brlcad/trunk/src/librt/primitives/pipe/pipe.c =================================================================== --- brlcad/trunk/src/librt/primitives/pipe/pipe.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/primitives/pipe/pipe.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -3341,7 +3341,7 @@ struct wdb_pipept *ptp; struct rt_pipe_internal *pip; fastf_t *vec; - int total_count; + size_t total_count; int double_count; int byte_count; unsigned long pipe_count; Modified: brlcad/trunk/src/librt/primitives/poly/poly.c =================================================================== --- brlcad/trunk/src/librt/primitives/poly/poly.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/primitives/poly/poly.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -63,7 +63,7 @@ { struct rt_pg_internal *pgp; int i; - ssize_t p; + size_t p; pgp = (struct rt_pg_internal *)ip->idb_ptr; RT_PG_CK_MAGIC(pgp); @@ -482,7 +482,7 @@ rt_pg_plot(struct bu_list *vhead, struct rt_db_internal *ip, const struct rt_tess_tol *ttol __attribute__((unused)), const struct bn_tol *tol __attribute__((unused))) { int i; - int p; /* current polygon number */ + size_t p; /* current polygon number */ struct rt_pg_internal *pgp; BU_CK_LIST_HEAD(vhead); @@ -514,7 +514,7 @@ rt_pg_plot_poly(struct bu_list *vhead, struct rt_db_internal *ip, const struct rt_tess_tol *ttol __attribute__((unused)), const struct bn_tol *tol __attribute__((unused))) { int i; - int p; /* current polygon number */ + size_t p; /* current polygon number */ struct rt_pg_internal *pgp; BU_CK_LIST_HEAD(vhead); @@ -572,7 +572,7 @@ struct vertex **verts; /* dynamic array of pointers */ struct vertex ***vertp;/* dynamic array of ptrs to pointers */ struct faceuse *fu; - int p; /* current polygon number */ + size_t p; /* current polygon number */ struct rt_pg_internal *pgp; RT_CK_DB_INTERNAL(ip); @@ -649,7 +649,7 @@ union record *rp; int i; int rno; /* current record number */ - int p; /* current polygon index */ + size_t p; /* current polygon index */ if (dbip) RT_CK_DBI(dbip); @@ -725,7 +725,7 @@ union record *rec; int i; int rno; /* current record number */ - int p; /* current polygon index */ + size_t p; /* current polygon index */ if (dbip) RT_CK_DBI(dbip); @@ -809,7 +809,7 @@ struct rt_pg_internal *pgp = (struct rt_pg_internal *)ip->idb_ptr; char buf[256]; - int i; + size_t i; RT_PG_CK_MAGIC(pgp); bu_vls_strcat(str, "polygon solid with no topology (POLY)\n"); @@ -867,7 +867,7 @@ rt_pg_ifree(struct rt_db_internal *ip) { struct rt_pg_internal *pgp; - int i; + size_t i; RT_CK_DB_INTERNAL(ip); @@ -921,7 +921,8 @@ struct rt_bot_internal *ip_bot; int max_pts; int max_tri; - int p, i; + size_t p; + int i; RT_CK_DB_INTERNAL(ip); BN_CK_TOL(tol); Modified: brlcad/trunk/src/librt/primitives/poly/poly_mirror.c =================================================================== --- brlcad/trunk/src/librt/primitives/poly/poly_mirror.c 2010-02-23 07:04:39 UTC (rev 37716) +++ brlcad/trunk/src/librt/primitives/poly/poly_mirror.c 2010-02-23 09:03:08 UTC (rev 37717) @@ -49,7 +49,8 @@ point_t mirror_pt; fastf_t ang; - int i, j; + size_t i; + int j; fastf_t *verts; fastf_t *norms; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |