Visit Jeremy's Blog.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 07-16-2004, 10:33 AM   #1
Registered: May 2002
Distribution: Slackware 9.1
Posts: 161

Rep: Reputation: 30
warning: no newline at end of file

hi people ..
i'm a beginner on c programming ..
i written a small script ..
#include <stdio.h>
int main ()
printf (" Mandrake Linux \n \t hello man \a");
return (0);
when i compile it . with gcc . it show the message]
warning: no newline at end of file

what should i do ..

Old 07-16-2004, 10:39 AM   #2
LQ Guru
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 74
You need to put a blank new line at the end of your source file.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
warning: deprecated use of label at end of compound statement abk4523 Programming 1 03-06-2005 10:50 AM
[Maybe redundant] main.cpp:1:18: warning: extra tokens at end of #include directive pycoucou Programming 2 10-26-2004 10:57 AM
warning: no final newline at the end of /etc/fstab Jeebizz Slackware 2 10-12-2004 03:19 PM
[mntent]:warning: no final newline at the end of /etc/fstab Rodcl Linux - Hardware 4 08-25-2002 03:58 PM
Warning: no newline at end of file acid_kewpie Programming 1 03-13-2002 03:53 AM

All times are GMT -5. The time now is 11:42 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration