I need to write a script that can find a bad record (for example: there is date field colom but value provided in the file for this field is N/A) then script shoud searches this pattern and then insert the whole record into the bad file.
Example:
File1
Name designation dateOfJoining... (1 Reply)
I need to write a script that can find a bad record (for example: there is date field colom but value provided in the file for this field is N/A) then script shoud searches this pattern and then insert the whole record into the bad file.
Example:
File1
Name designation dateOfJoining... (2 Replies)
I am trying to write binary data to a file. My program below:
#include <stdlib.h>
#include <stdio.h>
struct tinner {
int j;
int k;
};
struct touter {
int i;
struct tinner *inner;
};
int main() {
struct touter data;
data.i = 10;
struct tinner... (4 Replies)
hi ,
i m having a html file and this file looks like this
<ssl>
<name>PIA</name>
<enabled>true</enabled>
<listen-port>39370</listen-port>
</ssl>
<log>
<name>PIA</name>
</log>
<execute-queue>
<name>weblogic.kernel.Default</name>
... (7 Replies)
hi
I am doing a task that is i have to search for multiple pattern from a file's 9 th column and then redirect it to a new file
awk -F, 'BEGIN {OSF=","} { if ($9 == "OTF") print $0}' test1.tsv > test.tsv
and the patterns are OST. ODI,MIN LIKE OTF
Bit not getting the desired output... (11 Replies)
Can someone tell me how to do this?
Just a thought that entered my mind when learning about structs.
First thought was:
struct one
{
struct two;
}
struct two
{
three;
}
one->two->three
would this be how you would access "three"? (1 Reply)
Dear all,
I'm trying to manipulate a data file and putting a certain lines into one paragraph.
What am I actually want to do is that search some lines in a data file. These lines begin with "1\1\GINC-" and end with "\\@" or the following two empty lines as shown in blue.
A part of the text... (11 Replies)
Hi guys.
I have a header file including a structure like this:
typedef struct
{
int index = -1;
stack_node *head;
} stack;
But when compiling with cc it shows error at the assignment line (int index = -1):
error: expected ‘:', ‘,', ‘;', ‘}' or ‘__attribute__' before ‘=' token... (1 Reply)
Hi,
I have received an application that stores some properties in a file. The existing struct looks like this:
struct TData
{
UINT uSizeIncludingStrings;
// copy of Telnet data struct
UINT uSize;
// basic properties:
TCHAR szHost; //defined in Sshconfig
UINT iPortNr;
TCHAR... (2 Replies)
I created python code that produce output in the form of:
moses-red-sea=1.00.03
genesis-snake=2.03
deliverance=5.0.010
I need to take this output and create a "C" header file and have it look like this:
struct {
char *name;
char *fixed_version;
} filename_versions... (7 Replies)
Discussion started by: metallica1973
7 Replies
LEARN ABOUT NETBSD
radio
RADIO(9) BSD Kernel Developer's Manual RADIO(9)NAME
radio -- interface between low and high level radio drivers
DESCRIPTION
The radio device driver is divided into a high level, hardware independent layer, and a low level hardware dependent layer. The interface
between these is the radio_hw_if structure.
struct radio_hw_if {
int (*open)(void *, int, int, struct lwp *);
int (*close)(void *, int, int, struct lwp *);
int (*get_info)(void *, struct radio_info *);
int (*set_info)(void *, struct radio_info *);
int (*search)(void *, int);
};
The high level radio driver attaches to the low level driver when the latter calls radio_attach_mi. This call should be
void
radio_attach_mi(rhwp, hdlp, dev)
struct radio_hw_if *rhwp;
void *hdlp;
struct device *dev;
The radio_hw_if struct is as shown above. The hdlp argument is a handle to some low level data structure. It is sent as the first argument
to all the functions in radio_hw_if when the high level driver calls them. dev is the device struct for the hardware device.
The fields of radio_hw_if are described in some more detail below.
int open (void *, int flags, int fmt, struct lwp *p);
Optional.
Is called when the radio device is opened.
Returns 0 on success, otherwise an error code.
int close (void *, int flags, int fmt, struct lwp *p);
Optional.
Is called when the radio device is closed.
Returns 0 on success, otherwise an error code.
int get_info (void *, struct radio_info *);
Fill the radio_info struct.
Returns 0 on success, otherwise an error code.
int set_info (void *, struct radio_info *);
Set values from the radio_info struct.
Returns 0 on success, otherwise an error code.
int search (void *, int);
Returns 0 on success, otherwise an error code.
SEE ALSO radio(4)BSD December 20, 2005 BSD