03-11-2002
yes, that's right, if i just write:
printf("test\n");
then it appears properly on screen.
but what if i don't want to use \n ?
and also, the new bash line should appear _next to_ my data, but should not
overwrite it! i would like to know why...
10 More Discussions You Might Find Interesting
1. HP-UX
Hi, Haveing a little trouble with data protector (5.5) on HP-UX (11.11, 11.23)
under Xwindows Chameleon UNIX 97 (7.0 - its a old version)
I am trying to get the GUI for DP up and running on a HP-UX cell manager and I have the following problem.
The GUI starts up with no errors that I can... (2 Replies)
Discussion started by: Andrek
2 Replies
2. Programming
Hi all,
I am new to linux and got problem with pthread_mutex_trylock(). I have used mutex in my code. When I try to call pthread_mutex_trylock() on RECURSIVE type of mutex it overwrites adjacent memory location (that is global variable of type structure say x, memory allocated using malloc()). ... (5 Replies)
Discussion started by: liveshell
5 Replies
3. Shell Programming and Scripting
Dear Member,
OLD Question --> disable-completion not solved
My bash Menu script ping process problem.
If ping still running and users press SCREEN is Blank...
Cant Members help me.. kill signal or others scripting for my case, btw i use Linux..
Thanks,
Rico
My Bash Script :
... (1 Reply)
Discussion started by: carnegiex
1 Replies
4. Shell Programming and Scripting
I am unable to use clear or cls command on bash shell. I have recently installed Cygwin and am using that for practicing unix commands.
I see that I can use Ctrl + L to clear the screen. I created an alias in my .bashrc to do the same as
alias cls='^L'
This is how i defined other aliases ... (4 Replies)
Discussion started by: erora
4 Replies
5. Shell Programming and Scripting
I bet many people faced this problem before:
The command below will result in a blank file:
$ cat myfile | grep pattern > myfile
Is there any easy way to do it? (8 Replies)
Discussion started by: rlopes
8 Replies
6. Windows & DOS: Issues & Discussions
I use sugarsync to sync my vimrc across computers. I keep the _vimrc file in a syncing folder and in my home folder, I have a symbolic link ~\_vimrc pointing to ~\Synced Docs\_vimrc. On my mac I have a .vimrc symbolic link pointing at the _vimrc file. On the pc side, every time I open the _vimrc... (3 Replies)
Discussion started by: dp88
3 Replies
7. Shell Programming and Scripting
Hi,
I have a simple question about I/O redirection. the question is:
"How can I redirect all characters from a Bash screen to a file?"
Let me describe a little more: I know about I/O Redirection in Bash.
and also about stdin/stdout/stderr. something like: # ls 2>&1 1>ls.out
But!... (11 Replies)
Discussion started by: siavash
11 Replies
8. Shell Programming and Scripting
Hi All,
I was wondering how I can convert each line in an input file where fields are separated by variable width spaces into a CSV file. Below is the scenario what I am looking for.
My Input data in inputfile.txt
19 15657 15685 Sr2dReader 107.88 105.51... (4 Replies)
Discussion started by: vharsha
4 Replies
9. Shell Programming and Scripting
Hi folks
I have a script I wrote that basically parses a bunch of config and xml files works out were to add in the new content then spits out the data into a new file.
It all works - apart from the xml and config file format in the new file
with XML files the original XML (that ends up in... (2 Replies)
Discussion started by: dfinch
2 Replies
10. UNIX for Beginners Questions & Answers
Hello, everyone. I'm currently trying to write a command system for a Minecraft server using screen.
Here are the scripts I'm currently using.
0.sh
#!/bin/bash
screen -S Test114 -dm java -Xmx4G -jar server.jar nogui
1.sh
#!/bin/bash
args="$@"
args2="${args@Q}"
#args3=`printf '%q\n'... (2 Replies)
Discussion started by: Develon
2 Replies
LEARN ABOUT MOJAVE
fflush
FFLUSH(3) BSD Library Functions Manual FFLUSH(3)
NAME
fflush, fpurge -- flush a stream
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <stdio.h>
int
fflush(FILE *stream);
int
fpurge(FILE *stream);
DESCRIPTION
The function fflush() forces a write of all buffered data for the given output or update stream via the stream's underlying write function.
The open status of the stream is unaffected.
If the stream argument is NULL, fflush() flushes all open output streams.
The function fpurge() erases any input or output buffered in the given stream. For output streams this discards any unwritten output. For
input streams this discards any input read from the underlying object but not yet obtained via getc(3); this includes any text pushed back
via ungetc(3).
RETURN VALUES
Upon successful completion 0 is returned. Otherwise, EOF is returned and the global variable errno is set to indicate the error.
ERRORS
[EBADF] The stream argument is not an open stream, or, in the case of fflush(), not a stream open for writing.
The function fflush() may also fail and set errno for any of the errors specified for the routine write(2).
SEE ALSO
write(2), fclose(3), fopen(3), setbuf(3)
STANDARDS
The fflush() function conforms to ISO/IEC 9899:1990 (``ISO C90'').
BSD
June 4, 1993 BSD