Ticket #848: log-associate-project.diff
File log-associate-project.diff, 9.2 KB (added by , 16 years ago) |
---|
-
client/app_start.cpp
372 372 bool high_priority = (app_version->avg_ncpus < 1); 373 373 374 374 if (first_time && log_flags.task) { 375 msg_printf( result->project, MSG_INFO,375 msg_printf(wup->project, MSG_INFO, 376 376 "Starting %s", result->name 377 377 ); 378 378 } 379 379 if (log_flags.cpu_sched) { 380 msg_printf( result->project, MSG_INFO,380 msg_printf(wup->project, MSG_INFO, 381 381 "[cpu_sched] Starting %s%s", result->name, first_time?" (initial)":"(resume)" 382 382 ); 383 383 } … … 548 548 if (!pCEB(&environment_block, sandbox_account_service_token, FALSE)) { 549 549 if (log_flags.task) { 550 550 windows_error_string(error_msg, sizeof(error_msg)); 551 msg_printf( result->project, MSG_INFO,551 msg_printf(wup->project, MSG_INFO, 552 552 "Process environment block creation failed: %s", error_msg 553 553 ); 554 554 } … … 579 579 if (!pDEB(environment_block)) { 580 580 if (log_flags.task) { 581 581 windows_error_string(error_msg, sizeof(error_msg2)); 582 msg_printf( result->project, MSG_INFO,582 msg_printf(wup->project, MSG_INFO, 583 583 "Process environment block cleanup failed: %s", 584 584 error_msg2 585 585 ); … … 681 681 chdir(current_dir); 682 682 683 683 if (log_flags.task_debug) { 684 msg_printf( 0, MSG_INFO,684 msg_printf(wup->project, MSG_INFO, 685 685 "[task_debug] ACTIVE_TASK::start(): forked process: pid %d\n", pid 686 686 ); 687 687 } … … 848 848 } 849 849 850 850 if (log_flags.task_debug) { 851 msg_printf( 0, MSG_INFO,851 msg_printf(wup->project, MSG_INFO, 852 852 "[task_debug] ACTIVE_TASK::start(): forked process: pid %d\n", pid 853 853 ); 854 854 } -
client/app_graphics.cpp
73 73 } 74 74 75 75 if (log_flags.scrsave_debug) { 76 msg_printf( 0, MSG_INFO,76 msg_printf(wup->project, MSG_INFO, 77 77 "[scrsave_debug] ACTIVE_TASK::request_graphics_mode(): requesting graphics mode %s for %s", 78 78 xml_graphics_modes[m.mode], result->name 79 79 ); … … 102 102 if (app_client_shm.shm->graphics_reply.get_msg(buf)) { 103 103 app_client_shm.decode_graphics_msg(buf, gm); 104 104 if (log_flags.scrsave_debug) { 105 msg_printf( 0, MSG_INFO,105 msg_printf(wup->project, MSG_INFO, 106 106 "[scrsave_debug] ACTIVE_TASK::check_graphics_mode_ack(): got graphics ack %s for %s, previous mode %s", 107 107 buf, result->name, xml_graphics_modes[graphics_mode_acked] 108 108 ); -
client/file_xfer.cpp
203 203 } 204 204 iter++; 205 205 } 206 msg_printf( NULL, MSG_INTERNAL_ERROR,206 msg_printf(fxp->fip->project, MSG_INTERNAL_ERROR, 207 207 "File transfer for %s not found", fxp->fip->name 208 208 ); 209 209 return ERR_NOT_FOUND; -
client/cs_account.cpp
253 253 delete project; 254 254 } else { 255 255 if (lookup_project(project->master_url)) { 256 msg_printf( NULL, MSG_INFO,256 msg_printf(project, MSG_INFO, 257 257 "Duplicate account file %s - ignoring", name.c_str() 258 258 ); 259 259 delete project; -
client/cs_scheduler.cpp
802 802 // 803 803 for (i=0; i<sr.result_acks.size(); i++) { 804 804 if (log_flags.sched_op_debug) { 805 msg_printf( 0, MSG_INFO,805 msg_printf(project, MSG_INFO, 806 806 "[sched_op_debug] handle_scheduler_reply(): got ack for result %s\n", 807 807 sr.result_acks[i].name 808 808 ); … … 896 896 897 897 set_client_state_dirty("handle_scheduler_reply"); 898 898 if (log_flags.state_debug) { 899 msg_printf( 0, MSG_INFO,899 msg_printf(project, MSG_INFO, 900 900 "[state_debug] handle_scheduler_reply(): State after handle_scheduler_reply():" 901 901 ); 902 902 print_summary(); -
client/scheduler_op.cpp
814 814 continue; 815 815 } else if (strlen(buf)>1){ 816 816 if (log_flags.unparsed_xml) { 817 msg_printf( 0, MSG_INFO,817 msg_printf(project, MSG_INFO, 818 818 "[unparsed_xml] SCHEDULER_REPLY::parse(): unrecognized %s\n", buf 819 819 ); 820 820 } -
client/app_control.cpp
448 448 // 449 449 if (atp->process_control_queue.timeout(180)) { 450 450 if (log_flags.task_debug) { 451 msg_printf( NULL, MSG_INFO,451 msg_printf(atp->result->project, MSG_INFO, 452 452 "Restarting %s - message timeout", atp->result->name 453 453 ); 454 454 } … … 482 482 } else { 483 483 if (log_flags.task_debug) { 484 484 char errmsg[1024]; 485 msg_printf( 0, MSG_INFO,485 msg_printf(atp->result->project, MSG_INFO, 486 486 "[task_debug] task %s GetExitCodeProcess() failed - %s GLE %d (0x%x)", 487 487 atp->result->name, 488 488 windows_format_error_string( … … 508 508 // is probably a benchmark process; don't show error 509 509 // 510 510 if (!gstate.are_cpu_benchmarks_running() && log_flags.task_debug) { 511 msg_printf( NULL, MSG_INTERNAL_ERROR, "Process %d not found\n", pid);511 msg_printf(atp->wup->project, MSG_INTERNAL_ERROR, "Process %d not found\n", pid); 512 512 } 513 513 return false; 514 514 } … … 528 528 529 529 retval = current_disk_usage(disk_usage); 530 530 if (retval) { 531 msg_printf( 0, MSG_INTERNAL_ERROR,531 msg_printf(this->wup->project, MSG_INTERNAL_ERROR, 532 532 "Can't get task disk usage: %s", boincerror(retval) 533 533 ); 534 534 } else { … … 925 925 return false; 926 926 } 927 927 if (log_flags.app_msg_receive) { 928 msg_printf( NULL, MSG_INFO,928 msg_printf(this->wup->project, MSG_INFO, 929 929 "[app_msg_receive] got msg from slot %d: %s", slot, msg_buf 930 930 ); 931 931 } -
client/app.cpp
239 239 { 240 240 retval = detach_shmem(app_client_shm.shm); 241 241 if (retval) { 242 msg_printf( NULL, MSG_INTERNAL_ERROR,242 msg_printf(wup->project, MSG_INTERNAL_ERROR, 243 243 "Couldn't detach shared memory: %s", boincerror(retval) 244 244 ); 245 245 } 246 246 retval = destroy_shmem(shmem_seg_name); 247 247 if (retval) { 248 msg_printf( NULL, MSG_INTERNAL_ERROR,248 msg_printf(wup->project, MSG_INTERNAL_ERROR, 249 249 "Couldn't destroy shared memory: %s", boincerror(retval) 250 250 ); 251 251 } … … 313 313 retval = procinfo_setup(piv); 314 314 if (retval) { 315 315 if (log_flags.mem_usage_debug) { 316 msg_printf( 0, MSG_INTERNAL_ERROR,316 msg_printf(NULL, MSG_INTERNAL_ERROR, 317 317 "[mem_usage_debug] procinfo_setup() returned %d", retval 318 318 ); 319 319 } … … 689 689 else if (parse_double(buf, "<current_cpu_time>", x)) continue; 690 690 else { 691 691 if (log_flags.unparsed_xml) { 692 msg_printf( 0, MSG_INFO,692 msg_printf(project, MSG_INFO, 693 693 "[unparsed_xml] ACTIVE_TASK::parse(): unrecognized %s\n", buf 694 694 ); 695 695 } … … 753 753 else delete atp; 754 754 } else { 755 755 if (log_flags.unparsed_xml) { 756 msg_printf( 0, MSG_INFO,756 msg_printf(NULL, MSG_INFO, 757 757 "[unparsed_xml] ACTIVE_TASK_SET::parse(): unrecognized %s\n", buf 758 758 ); 759 759 } … … 881 881 fip->status = FILE_PRESENT; 882 882 } 883 883 } else { 884 msg_printf( 0, MSG_INTERNAL_ERROR, "Can't find uploadable file %s", p);884 msg_printf(wup->project, MSG_INTERNAL_ERROR, "Can't find uploadable file %s", p); 885 885 } 886 886 sprintf(path, "%s/%s", slot_dir, buf); 887 887 delete_project_owned_file(path, true); // delete the link file