Go to the source code of this file.
◆ BOF
◆ ENDIAN_1
◆ ENDIAN_2
◆ ENDIAN_3
◆ ENDIAN_4
◆ EXCEL_VERS
◆ FLOAT
◆ INTEGER
◆ LABEL
◆ WORKSHEET
◆ close_xls()
◆ create_xls()
| create_xls |
( |
char * |
name | ) |
|
Definition at line 185 of file libbif.c.
198 printf(
"Error opening file %s\n",
name);
int open(const char *pathname, int flags, mode_t mode)
◆ do_eof()
Definition at line 396 of file libbif.c.
400 char buf[]={0x0a,0x00,0x00,0x00};
ssize_t write(int fd, const void *buf, size_t count)
volatile int buf[CACHE_FLUSH_BUFFER_SIZE_INTS]
◆ do_float()
| do_float |
( |
int |
fd, |
|
|
double |
value, |
|
|
int |
row, |
|
|
int |
column |
|
) |
| |
Definition at line 270 of file libbif.c.
277 short s_row,s_column;
278 unsigned char *sptr,*dptr;
280 s_column=(short)column;
282 floatrec.lo_opcode=0x00;
283 floatrec.hi_length=0xf;
284 floatrec.lo_length=0x00;
288 floatrec.hi_row=(char)(s_row&0xff);
289 floatrec.lo_row=(char)((s_row>>8)&0xff);
290 floatrec.hi_column=(char)(s_column&0xff);
291 floatrec.lo_column=(char)((s_column>>8)&0xff);
292 sptr =(
unsigned char *) &value;
293 dptr =(
unsigned char *) &floatrec.data;
339 printf(
"Excel output not supported on this architecture.\n");
ssize_t write(int fd, const void *buf, size_t count)
◆ do_header()
Definition at line 210 of file libbif.c.
ssize_t write(int fd, const void *buf, size_t count)
◆ do_int()
| do_int |
( |
int |
fd, |
|
|
int |
val, |
|
|
int |
row, |
|
|
int |
column |
|
) |
| |
Definition at line 234 of file libbif.c.
239 short s_row,s_column;
241 s_column=(short)column;
243 intrec.lo_opcode=0x00;
244 intrec.hi_length=0x09;
245 intrec.lo_length=0x00;
249 intrec.hi_row=(char)s_row&0xff;
250 intrec.lo_row=(char)(s_row>>8)&0xff;
251 intrec.hi_column=(char)(s_column&0xff);
252 intrec.lo_column=(char)(s_column>>8)&0xff;
253 intrec.hi_data=(
val & 0xff);
254 intrec.lo_data=(
val & 0xff00)>>8;
ssize_t write(int fd, const void *buf, size_t count)
◆ do_label()
| do_label |
( |
int |
fd, |
|
|
char * |
string, |
|
|
int |
row, |
|
|
int |
column |
|
) |
| |
Definition at line 353 of file libbif.c.
360 short s_row,s_column;
363 labelrec.str_array[
i]=0;
365 s_column=(short)column;
367 labelrec.hi_opcode=
LABEL;
368 labelrec.lo_opcode=0x00;
369 labelrec.hi_length=0x08;
370 labelrec.lo_length=0x01;
374 labelrec.hi_row=(char)(s_row&0xff);
375 labelrec.lo_row=(char)((s_row>>8)&0xff);
376 labelrec.hi_column=(char)(s_column&0xff);
377 labelrec.lo_column=(char)((s_column>>8)&0xff);
378 labelrec.string_length=
i;
382 strcpy(labelrec.str_array,
string);
ssize_t write(int fd, const void *buf, size_t count)
◆ endian()
Definition at line 411 of file libbif.c.
413 long long foo = 0x0102030405060708LL;
414 long foo1 = 0x012345678;
415 unsigned char *
c,c1,c2,c3,c4,c5,c6,c7,c8;
416 c=(
unsigned char *)&foo;
431 if( (c1==0x08) && (c2==0x07) && (c3==0x06) && (c4==0x05) &&
432 (c5==0x04) && (c6==0x03) && (c7==0x02) && (c8==0x01) )
435 if( (c1==0x01) && (c2==0x02) && (c3==0x03) && (c4==0x04) &&
436 (c5==0x05) && (c6==0x06) && (c7==0x07) && (c8==0x08) )
439 if( (c1==0x04) && (c2==0x03) && (c3==0x02) && (c4==0x01) &&
440 (c5==0x08) && (c6==0x07) && (c7==0x06) && (c8==0x05) )
442 c=(
unsigned char *)&foo1;
448 if( (c1==0x34) && (c2==0x12) && (c3==0x78) && (c4==0x56))
◆ junk
◆ junkp