X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:content-type:date:from:message-id:mime-version :subject:to:content-transfer-encoding; q=dns; s=default; b=s6oke WVAtXK6OauZaKaLVkQhYFDTVP31Nl0YubOrlT+H8aZFV0ZA5RT/mNdjGdlJtBAVk G9IHonurjDIjFyryHgkbBTGSjY1lxY3zTpuwSoLG2Oe/jWyz1yEugXem/d/53F3f k3i9rHVmuVZdLXmNx6qgDvpHKpXy1NwB/U3hfk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:content-type:date:from:message-id:mime-version :subject:to:content-transfer-encoding; s=default; bh=UPODDRnE9rm i5b12WQxcOLdaYFE=; b=SKmdTXTisO2lHz++lj6cDS/GdqLAxwhVT/z60ryo/N6 pNYeaazMMUwjDq//00hvHLZONwV3KLDaQ/VG1Y6mZMX4tuObhSvgM+MT9kJs8jav D/4DT0b1/vnnER6Hw7BQF23QqMWKDEC+Idr6nQYJ7+3lJV2rKglJHxeGIckSld88 = Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.1 required=5.0 tests=BAYES_50,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.2 X-HELO: mout.gmx.net Content-Type: text/plain; charset="utf-8" Date: Wed, 23 Apr 2014 16:06:34 +0200 From: "qq qq" Message-ID: <20140423140635.156430@gmx.com> MIME-Version: 1.0 Subject: Cygwin's writev() non-standard behavior To: cygwin AT cygwin DOT com x-registered: 0 Content-Transfer-Encoding: 8bit writev() does not accept count 0 but it should $ cat test.c #include #include #include #include #include int main() {  struct iovec vec;  memset(&vec, 0, sizeof(vec));  if (writev(1, &vec, 0) < 0)    perror("writev");  return 0; } Linux: $ gcc -Wall test.c $ ./a.out Cygwin: $ gcc -Wall test.c $ ./a.exe writev: Invalid argument This behavior is buggy per:       EINVAL ... the vector count count is less than zero or greater than the permitted maximum ... -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple