Changeset 335 for devel/5.X/pbs.i
- Timestamp:
- 03/10/15 11:46:37 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
devel/5.X/pbs.i
r331 r335 23 23 #include "log.h" 24 24 25 #define SARA_DEBUG 1 26 27 //extern int pbs_errno; 25 #define SARA_DEBUG 0 28 26 29 27 %} … … 44 42 int i=0, size=0; 45 43 46 // printf("Python --> C\n"); 47 48 if (SARA_DEBUG) printf("Converteren python -> c (struct batch_status *):\n"); 44 if (SARA_DEBUG) printf("Convert python -> c (struct batch_status *):\n"); 49 45 50 46 size = Get_List_Size($input); … … 104 100 // printf("Python --> C\n"); 105 101 106 if (SARA_DEBUG) printf("Convert erenpython -> c (struct attrl *):\n");102 if (SARA_DEBUG) printf("Convert python -> c (struct attrl *):\n"); 107 103 108 104 size = Get_List_Size($input); … … 125 121 return NULL; 126 122 127 // This will skip pthe wrong entry123 // This will skip the wrong entry 128 124 // continue; 129 125 } … … 145 141 146 142 } // end for 143 147 144 if (SARA_DEBUG) printf("\t</Contents>\n"); 148 145 } // end struct attrl *IN typemap … … 159 156 // printf("Python --> C\n"); 160 157 161 if (SARA_DEBUG) printf("Convert erenpython -> c (struct attropl *):\n");158 if (SARA_DEBUG) printf("Convert python -> c (struct attropl *):\n"); 162 159 163 160 size = Get_List_Size($input); … … 244 241 245 242 PyObject *obj_batch; 246 struct batch_status *ptr ;243 struct batch_status *ptr, *org; 247 244 int i=0, len=0; 248 245 249 // printf("Ja we are in bussniss\n"); 250 if (SARA_DEBUG) printf("Converteren c (struct batch_status *) -> python:\n"); 246 if (SARA_DEBUG) printf("Convert c (struct batch_status *) -> python:\n"); 251 247 252 248 // Deterime length of list 253 249 // 254 ptr = $1; 250 org = $1; 251 ptr = org; 255 252 while (ptr != NULL) { 256 253 len++; … … 274 271 } 275 272 276 free(ptr);277 273 if (SARA_DEBUG) printf("\t</Contents>\n"); 278 274 } // end typemap struct batch_status * … … 283 279 int i=0, len=0; 284 280 285 if (SARA_DEBUG) printf("Convert erenc (struct attrl *) -> python:\n");281 if (SARA_DEBUG) printf("Convert c (struct attrl *) -> python:\n"); 286 282 287 283 ptr = $1; … … 302 298 ptr = ptr->next; 303 299 } 304 305 free(ptr);306 300 if (SARA_DEBUG) printf("\t</Contents>\n"); 307 301 } // end typemap struct attrl * … … 312 306 int i=0, len=0; 313 307 314 if (SARA_DEBUG) printf("Convert erenc (struct attropl *) -> python:\n");308 if (SARA_DEBUG) printf("Convert c (struct attropl *) -> python:\n"); 315 309 316 310 ptr = $1; … … 330 324 } 331 325 332 free(ptr);333 326 if (SARA_DEBUG) printf("\t</Contents>\n"); 334 327 } // end typemap struct attropl * … … 340 333 341 334 if (SARA_DEBUG) 342 printf("Convert erenchar ** -> python list\n");335 printf("Convert char ** -> python list\n"); 343 336 344 337 … … 513 506 // 514 507 %nodefault; 515 // %include "pbs_python.h" 508 509 516 510 %include "pbs_ifl.h" 517 511 %include "rm.h" 518 512 %include "log.h" 519 513 %include "pbs_error.h" 520 521 522 // Iets van uhhh..... obsolete523 // %ignore pbs_errno;524 //%include <pbs_error.h>525 526 527 /*528 %feature("shadow") attrl::__str__ {529 def __str__(self): print self.name + self.value;530 }531 %extend attrl {532 void __str__();533 }534 */535 514 536 515 /* not used … … 561 540 printf("Bas free attrl\n"); 562 541 563 /* 564 free(self); 565 */ 542 // free(self); 566 543 } 567 544 } … … 584 561 printf("Bas free attropl\n"); 585 562 586 /* 587 free(self); 588 */ 563 // free(self); 589 564 } 590 565 }
Note: See TracChangeset
for help on using the changeset viewer.