[haiku-commits] Re: haiku: hrev50308 - in src: add-ons/mail_daemon/outbound_protocols/smtp servers/app/drawing/interface/html5 add-ons/accelerants/radeon add-ons/media/media-add-ons servers/app
- From: waddlesplash <waddlesplash@xxxxxxxxx>
- To: haiku-commits@xxxxxxxxxxxxx
- Date: Fri, 13 May 2016 16:00:04 -0400
On Fri, May 13, 2016 at 3:53 PM, Rene Gollent <anevilyak@xxxxxxxxx> wrote:
+#ifdef USE_SSL
+ if (use_ssl) {
+
SSL_write(ssl,data,bufferLen);
+ } else {
+ send (fSocket,data,
bufferLen,0);
+ }
+#else
This change introduces a style violation.
Extraneous braces, got it. Fixing.
+#ifdef USE_SSL
+ if (use_ssl) {
+ if (SSL_write(ssl,data,bufferLen -
3) < 0)
+ break;
+ } else {
+ if (send (fSocket,data, bufferLen -
3,0) < 0)
+ break; // Stop when an error
happens.
+ }
+#else
Ditto.
What's the violation here? The code inside first if() technically
doesn't *need* a {}, but since it's more than one LoC, isn't having
braces OK?
Or are you referring to the #if indentation?
-waddlesplash
Other related posts: