When run it, segment fault.
What is wrong?
#include <stdio.h>
#include <stdlib.h>
const int max =20;
//****************************************************
// Input Matrix
//****************************************************
void inMatrixAA(int *AA, int row, int col)... (9 Replies)
Hi,
I am using bash. My question concerns cutting out segments of a string. Given the following filename:
S2002254132542.L1A_MLAC.x.hdf
I have been able to successfully separate the string at the periods (.):
$ L1A_FILE=S2002254132542.L1A_MLAC.x.hdf
$ BASE=$(echo $L1A_FILE | awk -F.... (5 Replies)
I need help in removing a leading zero in a particular position.
For eg.: XYZ*04567472*0099*020091231*0123*0.12
In the above line, I want to replace "*0123" with "123" and "0.12" with ".12". I want to remove the leading zero only in position number 4 and 5 (the bolded segments)
I was able... (10 Replies)
I mean, I malloc a segment of memory, maybe 1k maybe 20bytes.. assume the pointer is pMem How can I know the content pMem refered is all Zero or \0 . I know memcmp but the second parameter should another memory address... thanx (4 Replies)
Hi,
Whether the following piece of code is placed in the read-only memory of code (text) segment or data segment?
char *a = "Hello";
I am getting two different answers while searching in google :( that's why the confusion is (7 Replies)
I always get segment fault, why? can sb help me and modify it, I have spend on much time on
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#include <string.h>
#define MAX 10
pthread_t thread;
void *thread1()
{
int *a;
int i, n;
... (1 Reply)
I have a file with a combination of binary characters and words, and need to trim out the segment i.e. SleeperThreadAborting {{username::RAB2002}} {{scriptname::scs_get_pending_by_loc}} and put the lists into a text file.
Luckily, the segment I am looking for i.e. has readable words ... (8 Replies)
Discussion started by: Daniel Gate
8 Replies
LEARN ABOUT DEBIAN
getnodebyname
GETNODEBYNAME(3) Library Functions Manual GETNODEBYNAME(3)NAME
getnodebyname - DECnet node entry retrieval by address
SYNOPSIS
#include <netdnet/dn.h>
#include <netdnet/dnetdb.h>
struct nodeent *getnodebyname (char *name)
DESCRIPTION
getnodebyname searches the decnet hosts file for the DECnet node with name equal to name and returns node information into the nodeent
structure.
If no entry is found, returns NULL
EXAMPLE
#include <netdnet/dn.h>
#include <netdnet/dnetdb.h>
#include <sys/socket.h>
main(void)
{
struct nodeent *dp;
if ( (dp=getnodebyname("mv3100")) == NULL)
printf("Error, cannot find node entry");
else
printf("Node name is %s",dp->n_name);
}
SEE ALSO dnet_htoa(3), dnet_ntoa(3), dnet_conn(3), dnet_addr(3), getnodebyaddr(3), getnodeadd(3), setnodeent(3)DECnet database functions July 28, 1998 GETNODEBYNAME(3)