Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 352682

Summary: [TCF] TCF client error messages should be issued to stderr; also, connect command should provide some retroaction
Product: [Tools] TCF Reporter: Daniel U. Thibault <d.u.thibault>
Component: AgentAssignee: Project Inbox <tcf.agent-inbox>
Status: RESOLVED FIXED QA Contact: Eugene Tarassov <eugene>
Severity: enhancement    
Priority: P3 CC: cdtdoug
Version: unspecified   
Target Milestone: 0.4.0   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
diff file for agent/main/cmdline.c patch eugene: iplog+

Description Daniel U. Thibault CLA 2011-07-20 17:15:18 EDT
Build Identifier: 20110505-1223

A handful of error messages issued by the TCF client (agent/main/cmdline.c) are sent to stdout instead of stderr. This is easily fixed by switching the offending 'printf(' statements into 'fprintf(stderr, '.

Secondly, the lack of retroaction provided by the 'connect' command when it works normally is unsettling. A simple printf statement in the connect_callback function is all that is required to fix this.

(A patch will follow shortly)

Reproducible: Always

Steps to Reproduce:
1. display_tcf_reply, line 106: printf("Reply error... ==> fprintf(stderr, "Reply error...
2. cmd_tcf, line 134: printf("Error... ==> fprintf(stderr, "Error...
3. cmd_tcf, line 143: printf("Error... ==> fprintf(stderr, "Error...
4. connect_callback, line 234: insert this:
   printf(" Connection established with %s\n", c->peer_name);
Comment 1 Daniel U. Thibault CLA 2011-07-20 17:27:08 EDT
Created attachment 200037 [details]
diff file for agent/main/cmdline.c patch

The diff header refers to my local paths and will thus need to be tweaked.
Comment 2 Martin Oberhuber CLA 2011-07-21 08:44:29 EDT
Please file TCF issues against "Product = TCF" under Tools now.
Comment 3 Eugene Tarassov CLA 2011-07-21 13:42:04 EDT
I have committed the patch.
Thanks!