Project

General

Profile

Bug #627 ยป src.ticket627.diff

patches for ticket #627 in src/base.h, src/configfile-glue.h - agrostis, 2006-11-19 22:35

View differences:

src-diff/base.h Mon Nov 20 00:45:43 2006
83 83
typedef enum { T_CONFIG_UNSET, 
84 84
		T_CONFIG_STRING, 
85 85
		T_CONFIG_SHORT,
86
		T_CONFIG_INT,
86 87
		T_CONFIG_BOOLEAN, 
87 88
		T_CONFIG_ARRAY, 
88 89
		T_CONFIG_LOCAL, 
src-diff/configfile-glue.c Mon Apr 24 02:31:47 2006
78 78
			}
79 79
			break;
80 80
		case T_CONFIG_SHORT:
81
		case T_CONFIG_INT:
81 82
			switch(du->type) {
82 83
			case TYPE_INTEGER: {
83 84
				data_integer *di = (data_integer *)du;
84
				
85
				*((unsigned short *)(cv[i].destination)) = di->value;
85
				if (cv[i].type == T_CONFIG_SHORT) {
86
					*((unsigned short *)(cv[i].destination)) = di->value;
87
				} else {
88
					*((int *)(cv[i].destination)) = di->value;
89
				}
86 90
				break;
87 91
			}
88 92
			case TYPE_STRING: {
    (1-1/1)